Exemplo n.º 1
0
 public async Task Run([ServiceBusTrigger(
                            ServiceBusConstants.TopicNames.ProviderSourceDatasetCleanup,
                            ServiceBusConstants.TopicSubscribers.CleanupTestResultsForSpecificationProviders,
                            Connection = ServiceBusConstants.ConnectionStringConfigurationKey)] Message message)
 {
     await Run(message,
               async() =>
     {
         await _testResultsService.CleanupTestResultsForSpecificationProviders(message);
     });
 }
 public async Task Run([ServiceBusTrigger(
                            ServiceBusConstants.TopicNames.ProviderSourceDatasetCleanup,
                            ServiceBusConstants.TopicSubscribers.CleanupTestResultsForSpecificationProviders,
                            Connection = ServiceBusConstants.ConnectionStringConfigurationKey)] Message message)
 {
     try
     {
         _correlationIdProvider.SetCorrelationId(message.GetCorrelationId());
         await _testResultsService.CleanupTestResultsForSpecificationProviders(message);
     }
     catch (Exception exception)
     {
         _logger.Error(exception, $"An error occurred getting message from topic: {ServiceBusConstants.TopicNames.ProviderSourceDatasetCleanup}");
         throw;
     }
 }