Esempio n. 1
0
        async Task Faulted(BehaviorContext <TInstance> context)
        {
            if (context.TryGetExceptionContext(out ConsumeExceptionEventContext <TInstance, TException> exceptionContext))
            {
                var message = await _asyncMessageFactory(exceptionContext).ConfigureAwait(false);

                var producer = await context.GetProducer(exceptionContext, _nameProvider(exceptionContext));

                await producer.Produce(message, _pipe).ConfigureAwait(false);
            }
        }