예제 #1
0
 private void HandleFirstCorrelation(CorrelationTestMessage1 message)
 {
     _logger.LogInformation("Received correlation message 1. Correlatio ID {correlation}", message.CorrelationId);
     _publisher.SendAsync(new CorrelationTestMessage2
     {
         CorrelationId = message.CorrelationId
     });
 }
예제 #2
0
        private void ExecuteTask(object state)
        {
            var correlationId  = Guid.NewGuid();
            var correlationKey = $"COR-{correlationId}";

            _logger.LogInformation("Starting correlation chain with {correlation}", correlationKey);
            var testMessage = new CorrelationTestMessage1
            {
                CorrelationId = correlationKey
            };

            _publisher.SendAsync(testMessage);
        }