C# Class Microsoft.AspNet.WebHooks.WebHookQueueHandler

Provides an abstract IWebHookHandler implementation which can be used to enqueue WebHooks for processing outside their immediate HTTP request/response context. This can for example be used to process WebHooks by a separate agent or at another time. It can also be used for WebHooks where the processing take longer than permitted by the immediate HTTP request/response context.
Inheritance: WebHookHandler
Exibir arquivo Open project: aspnet/WebHooks

Public Methods

Method Description
EnqueueAsync ( WebHookQueueContext context ) : System.Threading.Tasks.Task

Enqueues an incoming WebHook for processing outside its immediate HTTP request/response context. Any exception thrown will result in an HTTP error response being returned to the party generating the WebHook.

ExecuteAsync ( string receiver, WebHookHandlerContext context ) : System.Threading.Tasks.Task

Protected Methods

Method Description
WebHookQueueHandler ( ) : System

Initializes a new instance of the WebHookQueueHandler class with a default WebHookHandler.Order of 50 and by default accepts WebHooks from all receivers. To limit which receiver this IWebHookHandler will receive WebHook requests from, set the WebHookHandler.Receiver property to the name of that receiver.

Method Details

EnqueueAsync() public abstract method

Enqueues an incoming WebHook for processing outside its immediate HTTP request/response context. Any exception thrown will result in an HTTP error response being returned to the party generating the WebHook.
public abstract EnqueueAsync ( WebHookQueueContext context ) : System.Threading.Tasks.Task
context WebHookQueueContext The for the WebHook to be enqueued.
return System.Threading.Tasks.Task

ExecuteAsync() public method

public ExecuteAsync ( string receiver, WebHookHandlerContext context ) : System.Threading.Tasks.Task
receiver string
context WebHookHandlerContext
return System.Threading.Tasks.Task

WebHookQueueHandler() protected method

Initializes a new instance of the WebHookQueueHandler class with a default WebHookHandler.Order of 50 and by default accepts WebHooks from all receivers. To limit which receiver this IWebHookHandler will receive WebHook requests from, set the WebHookHandler.Receiver property to the name of that receiver.
protected WebHookQueueHandler ( ) : System
return System