SessionMessageProcessor.CompleteProcessingMessageAsync Method

Definition

This method completes processing of the specified message, after the job function has been invoked.

protected internal virtual System.Threading.Tasks.Task CompleteProcessingMessageAsync (Microsoft.Azure.WebJobs.ServiceBus.ServiceBusSessionMessageActions actions, Azure.Messaging.ServiceBus.ServiceBusReceivedMessage message, Microsoft.Azure.WebJobs.Host.Executors.FunctionResult result, System.Threading.CancellationToken cancellationToken);
abstract member CompleteProcessingMessageAsync : Microsoft.Azure.WebJobs.ServiceBus.ServiceBusSessionMessageActions * Azure.Messaging.ServiceBus.ServiceBusReceivedMessage * Microsoft.Azure.WebJobs.Host.Executors.FunctionResult * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.CompleteProcessingMessageAsync : Microsoft.Azure.WebJobs.ServiceBus.ServiceBusSessionMessageActions * Azure.Messaging.ServiceBus.ServiceBusReceivedMessage * Microsoft.Azure.WebJobs.Host.Executors.FunctionResult * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Protected Friend Overridable Function CompleteProcessingMessageAsync (actions As ServiceBusSessionMessageActions, message As ServiceBusReceivedMessage, result As FunctionResult, cancellationToken As CancellationToken) As Task

Parameters

actions
ServiceBusSessionMessageActions

The set of actions that can be performed on a ServiceBusReceivedMessage.

result
Microsoft.Azure.WebJobs.Host.Executors.FunctionResult

The Microsoft.Azure.WebJobs.Host.Executors.FunctionResult from the job invocation.

cancellationToken
CancellationToken

The CancellationToken to use

Returns

A Task that will complete the message processing.

Remarks

The message is completed by the ServiceBus SDK based on how the AutoCompleteMessages option is configured. E.g. if AutoCompleteMessages is false, it is up to the job function to complete the message.

Applies to