Table of Contents

Class EndpointGovernanceMiddleware

Namespace
AsiBackbone.AspNetCore.Endpoints
Assembly
AsiBackbone.AspNetCore.dll

Middleware that evaluates AsiBackbone endpoint governance metadata before endpoint execution.

public sealed class EndpointGovernanceMiddleware
Inheritance
EndpointGovernanceMiddleware
Inherited Members

Constructors

EndpointGovernanceMiddleware(RequestDelegate, IOptions<EndpointGovernanceOptions>)

Initializes a new instance of the EndpointGovernanceMiddleware class.

public EndpointGovernanceMiddleware(RequestDelegate next, IOptions<EndpointGovernanceOptions> endpointOptions)

Parameters

next RequestDelegate

The next request delegate.

endpointOptions IOptions<EndpointGovernanceOptions>

The endpoint governance options.

Methods

InvokeAsync(HttpContext, IEndpointGovernanceService)

Evaluates endpoint governance metadata and either continues execution or writes a failure result.

public Task InvokeAsync(HttpContext httpContext, IEndpointGovernanceService governanceService)

Parameters

httpContext HttpContext

The current HTTP context.

governanceService IEndpointGovernanceService

The endpoint governance service.

Returns

Task

A task that completes when the middleware has run.