Added service cache feature flag
Updated scheduler and moved to its own dedicated database
This commit is contained in:
@@ -7,7 +7,8 @@ namespace PostFundManagement.Domain.Quartz;
|
||||
[DisallowConcurrentExecution]
|
||||
public sealed class MediatorJob<TNotification>(IMediator mediator) : IJob where TNotification : IEvent
|
||||
{
|
||||
public async Task Execute(IJobExecutionContext context)
|
||||
|
||||
public async ValueTask Execute(IJobExecutionContext context, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (context.Recovering)
|
||||
Trace.WriteLine($"CRITICAL RECOVERY: Resurrecting job '{typeof(TNotification).Name}' after a previous cluster node crashed mid-execution.");
|
||||
@@ -43,7 +44,7 @@ public sealed class MediatorJob<TNotification>(IMediator mediator) : IJob where
|
||||
catch (OperationCanceledException) when (context.CancellationToken.IsCancellationRequested)
|
||||
{
|
||||
Trace.WriteLine($"Job '{typeof(TNotification).Name}' was gracefully interrupted by the cluster control plane.");
|
||||
|
||||
|
||||
activity?.SetStatus(ActivityStatusCode.Ok);
|
||||
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user