Replace AsyncInitWorker with ConsumerInitWorker

Replaced the `AsyncInitWorker` background service with the new `ConsumerInitWorker`, which introduces enhanced error handling, logging, and configurability for RabbitMQ consumer initialization.

Updated `MessagingServiceDbContext` to remove the `UseCollation` configuration for the `Username` property in the `EmailAccount` entity, ensuring compatibility with the InMemory database.

Added the `ContinueOnInitFailure` property to `RabbitMqConfiguration` to allow the application to continue running if RabbitMQ consumer initialization fails.

Cleaned up unused `using` directives in `DependencyInjection.cs` and removed the obsolete `AsyncInitWorker` class.
This commit is contained in:
2026-08-18 16:38:25 +02:00
parent 26c78d32ae
commit 76fc005b02
5 changed files with 40 additions and 24 deletions

View File

@@ -81,5 +81,7 @@ namespace DigitalData.MessagingService.RabbitMQ
/// Maps directly to RabbitMQ prefetchCount. Recommended: 3–5.
/// </summary>
public ushort ConsumerConcurrency { get; set; } = 5;
public bool ContinueOnInitFailure { get; set; } = false;
}
}