UserInfoContextMiddleware Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Middleware that resolves user information from HTTP headers and stores it in AsyncLocal storage. This makes user context available throughout the async request flow.
public class UserInfoContextMiddleware
type UserInfoContextMiddleware = class
Public Class UserInfoContextMiddleware
- Inheritance
-
UserInfoContextMiddleware
Constructors
| Name | Description |
|---|---|
| UserInfoContextMiddleware(RequestDelegate, Func<HttpContext,Task<UserInfo>>) |
Initializes a new instance of the UserInfoContextMiddleware class. |
Methods
| Name | Description |
|---|---|
| InvokeAsync(HttpContext) |
Invokes the middleware to resolve and set user context. |