feat(Production): Complete production deployment infrastructure

- Add comprehensive health check system with multiple endpoints
- Add Prometheus metrics endpoint
- Add production logging configurations (5 strategies)
- Add complete deployment documentation suite:
  * QUICKSTART.md - 30-minute deployment guide
  * DEPLOYMENT_CHECKLIST.md - Printable verification checklist
  * DEPLOYMENT_WORKFLOW.md - Complete deployment lifecycle
  * PRODUCTION_DEPLOYMENT.md - Comprehensive technical reference
  * production-logging.md - Logging configuration guide
  * ANSIBLE_DEPLOYMENT.md - Infrastructure as Code automation
  * README.md - Navigation hub
  * DEPLOYMENT_SUMMARY.md - Executive summary
- Add deployment scripts and automation
- Add DEPLOYMENT_PLAN.md - Concrete plan for immediate deployment
- Update README with production-ready features

All production infrastructure is now complete and ready for deployment.
This commit is contained in:
2025-10-25 19:18:37 +02:00
parent caa85db796
commit fc3d7e6357
83016 changed files with 378904 additions and 20919 deletions

View File

@@ -4,12 +4,12 @@ declare(strict_types=1);
namespace App\Framework\Queue\Wrappers;
use App\Framework\Core\ValueObjects\Duration;
use App\Framework\Queue\Queue;
use App\Framework\Queue\RetryStrategyHelper;
use App\Framework\Queue\ValueObjects\JobMetadata;
use App\Framework\Queue\ValueObjects\JobPayload;
use App\Framework\Queue\ValueObjects\QueuePriority;
use App\Framework\Queue\ValueObjects\JobMetadata;
use App\Framework\Queue\RetryStrategyHelper;
use App\Framework\Core\ValueObjects\Duration;
use App\Framework\Retry\RetryStrategy;
/**
@@ -22,7 +22,8 @@ final readonly class EmailQueue
{
public function __construct(
private Queue $queue
) {}
) {
}
/**
* Push any object as an email job
@@ -166,6 +167,7 @@ final readonly class EmailQueue
public function popEmail(): ?object
{
$payload = $this->queue->pop();
return $payload?->job;
}
@@ -177,6 +179,7 @@ final readonly class EmailQueue
public function peekEmail(): ?object
{
$payload = $this->queue->peek();
return $payload?->job;
}
@@ -227,7 +230,7 @@ final readonly class EmailQueue
'type' => 'email',
'size' => $this->size(),
'is_empty' => $this->isEmpty(),
...$stats
...$stats,
];
}
@@ -291,7 +294,7 @@ final readonly class EmailQueue
$tempEmails = [];
// Pop all emails temporarily
while (!$this->isEmpty()) {
while (! $this->isEmpty()) {
$payload = $this->popEmailWithMetadata();
if ($payload === null) {
break;
@@ -320,6 +323,7 @@ final readonly class EmailQueue
public function getEmailCountByPriority(): array
{
$stats = $this->getStats();
return $stats['priority_breakdown'] ?? [];
}
@@ -334,7 +338,7 @@ final readonly class EmailQueue
$tempEmails = [];
// Pop all emails temporarily
while (!$this->isEmpty()) {
while (! $this->isEmpty()) {
$payload = $this->popEmailWithMetadata();
if ($payload === null) {
break;
@@ -365,7 +369,7 @@ final readonly class EmailQueue
return [
'pending' => $this->size(),
'scheduled' => count($this->getScheduledEmails()),
'immediate' => $this->size() - count($this->getScheduledEmails())
'immediate' => $this->size() - count($this->getScheduledEmails()),
];
}
@@ -416,4 +420,4 @@ final readonly class EmailQueue
$this->pushNotificationEmail($email);
}
}
}
}