Class RespondAsyncExecuteExtensions
- Namespace
- MassTransit
- Assembly
- MassTransit.Abstractions.dll
public static class RespondAsyncExecuteExtensions
- Inheritance
-
RespondAsyncExecuteExtensions
- Inherited Members
Methods
RespondAsync(ConsumeContext, object, Action<SendContext>)
public static Task RespondAsync(this ConsumeContext context, object message, Action<SendContext> callback)
Parameters
context
ConsumeContextmessage
objectcallback
Action<SendContext>
Returns
- Task
The task which is completed once the Send is acknowledged by the broker
RespondAsync(ConsumeContext, object, Func<SendContext, Task>)
Responds to the current message immediately, returning the Task for the sending message. The caller may choose to await the response to ensure it was sent, or allow the framework to wait for it (which will happen automatically before the message is acked)
public static Task RespondAsync(this ConsumeContext context, object message, Func<SendContext, Task> callback)
Parameters
context
ConsumeContextThe context to send the message
message
objectThe message
callback
Func<SendContext, Task>The callback for the send context
Returns
- Task
The task which is completed once the Send is acknowledged by the broker
RespondAsync(ConsumeContext, object, Type, Action<SendContext>)
Responds to the current message immediately, returning the Task for the sending message. The caller may choose to await the response to ensure it was sent, or allow the framework to wait for it (which will happen automatically before the message is acked)
public static Task RespondAsync(this ConsumeContext context, object message, Type messageType, Action<SendContext> callback)
Parameters
context
ConsumeContextThe context to send the message
message
objectThe message
messageType
TypeThe message type to send the object as
callback
Action<SendContext>The callback for the send context
Returns
- Task
The task which is completed once the Send is acknowledged by the broker
RespondAsync(ConsumeContext, object, Type, Func<SendContext, Task>)
Responds to the current message immediately, returning the Task for the sending message. The caller may choose to await the response to ensure it was sent, or allow the framework to wait for it (which will happen automatically before the message is acked)
public static Task RespondAsync(this ConsumeContext context, object message, Type messageType, Func<SendContext, Task> callback)
Parameters
context
ConsumeContextThe context to send the message
message
objectThe message
messageType
TypeThe message type to send the object as
callback
Func<SendContext, Task>The callback for the send context
Returns
- Task
The task which is completed once the Send is acknowledged by the broker
RespondAsync<T>(ConsumeContext, object, Action<SendContext<T>>)
Responds to the current message immediately, returning the Task for the sending message. The caller may choose to await the response to ensure it was sent, or allow the framework to wait for it (which will happen automatically before the message is acked)
public static Task RespondAsync<T>(this ConsumeContext context, object values, Action<SendContext<T>> callback) where T : class
Parameters
context
ConsumeContextThe context to send the message
values
objectThe values that map to the object
callback
Action<SendContext<T>>The callback for the send context
Returns
- Task
The task which is completed once the Send is acknowledged by the broker
Type Parameters
T
The message type
RespondAsync<T>(ConsumeContext, object, Func<SendContext<T>, Task>)
Responds to the current message immediately, returning the Task for the sending message. The caller may choose to await the response to ensure it was sent, or allow the framework to wait for it (which will happen automatically before the message is acked)
public static Task RespondAsync<T>(this ConsumeContext context, object values, Func<SendContext<T>, Task> callback) where T : class
Parameters
context
ConsumeContextThe context to send the message
values
objectThe values that map to the object
callback
Func<SendContext<T>, Task>The callback for the send context
Returns
- Task
The task which is completed once the Send is acknowledged by the broker
Type Parameters
T
The message type
RespondAsync<T>(ConsumeContext, T, Action<SendContext<T>>)
Responds to the current message immediately, returning the Task for the sending message. The caller may choose to await the response to ensure it was sent, or allow the framework to wait for it (which will happen automatically before the message is acked)
public static Task RespondAsync<T>(this ConsumeContext context, T message, Action<SendContext<T>> callback) where T : class
Parameters
context
ConsumeContextThe context to send the message
message
TThe message
callback
Action<SendContext<T>>The callback for the send context
Returns
- Task
The task which is completed once the Send is acknowledged by the broker
Type Parameters
T
The message type
RespondAsync<T>(ConsumeContext, T, Func<SendContext<T>, Task>)
Responds to the current message immediately, returning the Task for the sending message. The caller may choose to await the response to ensure it was sent, or allow the framework to wait for it (which will happen automatically before the message is acked)
public static Task RespondAsync<T>(this ConsumeContext context, T message, Func<SendContext<T>, Task> callback) where T : class
Parameters
context
ConsumeContextThe context to send the message
message
TThe message
callback
Func<SendContext<T>, Task>The callback for the send context
Returns
- Task
The task which is completed once the Send is acknowledged by the broker
Type Parameters
T
The message type