Update campaign handling

This commit is contained in:
2025-10-27 16:56:08 +09:00
parent 445bfe8273
commit 6b3733001a
7 changed files with 86 additions and 11 deletions

View File

@ -38,12 +38,12 @@ namespace Hcs.WebApp.BackgroundServices
try
{
var executor = executorFactory.CreateExecutor(client, operation);
await headquartersService.SetOperationStarted(operation.Id);
messageGuid = await executor.ExecuteAsync(stoppingToken);
}
catch
catch (Exception e)
{
// TODO: Добавить таймауты и макс количество попыток выполнения операции
state.EnqueueOperation(operation);
await headquartersService.SetOperationEndedWithFail(operation.Id, e.Message);
}
if (!string.IsNullOrEmpty(messageGuid))