Interface IHandlerInvoker
Identifies and invokes the correct method on a registered IMessageHandler<T> for received messages
public interface IHandlerInvoker
Methods
InvokeAsync(MessageEnvelope, SubscriberMapping, CancellationToken)
Identifies and calls the correct method on a registered IMessageHandler<T> for the given message
Task<MessageProcessStatus> InvokeAsync(MessageEnvelope messageEnvelope, SubscriberMapping subscriberMapping, CancellationToken token = default)
Parameters
messageEnvelope
MessageEnvelopeEnvelope of the message that is being handled
subscriberMapping
SubscriberMappingSubscriber mapping of the message that is being handled
token
CancellationTokenCancellation token which will be passed to the message handler
Returns
- Task<MessageProcessStatus>
Task representing the outcome of the message handler