AspNetCore.Docs/aspnetcore/includes/reset.md

463 B

Reset allows for the server to reset a HTTP/2 request with a specified error code. A reset request is considered aborted.

var resetFeature = httpContext.Features.Get<IHttpResetFeature>();
resetFeature.Reset(errorCode: 2);

Reset in the preceding code example specifies the INTERNAL_ERROR error code. For more information about HTTP/2 error codes, visit the HTTP/2 specification error code section.