223 references to ConnectionEndReason
Microsoft.AspNetCore.Server.Kestrel.Core (223)
Internal\Http\Http1ChunkedEncodingMessageBody.cs (1)
140KestrelMetrics.AddConnectionEndReason(_context.MetricsContext, ConnectionEndReason.UnexpectedEndOfRequestContent);
Internal\Http\Http1Connection.cs (23)
104_http1Output.Abort(ServerOptions.FinOnError ? new ConnectionAbortedException(CoreStrings.ConnectionAbortedByClient) : null!, ConnectionEndReason.TransportCompleted); 110_http1Output.Abort(new ConnectionAbortedException(CoreStrings.ConnectionAbortedByClient), ConnectionEndReason.TransportCompleted); 117public void Abort(ConnectionAbortedException abortReason, ConnectionEndReason reason) 127Abort(new ConnectionAbortedException(CoreStrings.ConnectionAbortedByApplication), ConnectionEndReason.AbortedByApp); 135public void StopProcessingNextRequest(ConnectionEndReason reason) 141internal override void DisableKeepAlive(ConnectionEndReason reason) 155KestrelMetrics.AddConnectionEndReason(MetricsContext, ConnectionEndReason.RequestHeadersTimeout); 163KestrelMetrics.AddConnectionEndReason(MetricsContext, ConnectionEndReason.MinRequestBodyDataRate); 625KestrelMetrics.AddConnectionEndReason(MetricsContext, ConnectionEndReason.InvalidRequestHeaders); 636KestrelMetrics.AddConnectionEndReason(MetricsContext, ConnectionEndReason.InvalidRequestHeaders); 661KestrelMetrics.AddConnectionEndReason(MetricsContext, ConnectionEndReason.InvalidRequestHeaders); 670KestrelMetrics.AddConnectionEndReason(MetricsContext, ConnectionEndReason.InvalidRequestHeaders); 736KestrelMetrics.AddConnectionEndReason(MetricsContext, ConnectionEndReason.OtherError); 785internal static ConnectionEndReason GetConnectionEndReason(Microsoft.AspNetCore.Http.BadHttpRequestException ex) 794return ConnectionEndReason.InvalidHttpVersion; 798return ConnectionEndReason.InvalidRequestLine; 811return ConnectionEndReason.InvalidRequestHeaders; 813return ConnectionEndReason.MaxRequestHeadersTotalSizeExceeded; 815return ConnectionEndReason.MaxRequestHeaderCountExceeded; 817return ConnectionEndReason.TlsNotSupported; 819return ConnectionEndReason.UnexpectedEndOfRequestContent; 823return ConnectionEndReason.OtherError; 834var reason = GetConnectionEndReason(ex);
Internal\Http\Http1ContentLengthMessageBody.cs (1)
249_context.DisableKeepAlive(ConnectionEndReason.MaxRequestBodySizeExceeded);
Internal\Http\Http1MessageBody.cs (5)
75_context.StopProcessingNextRequest(ConnectionEndReason.InvalidBodyReaderState); 110_context.StopProcessingNextRequest(ConnectionEndReason.InvalidBodyReaderState); 120_context.DisableKeepAlive(ConnectionEndReason.MaxRequestBodySizeExceeded); 210KestrelMetrics.AddConnectionEndReason(context.MetricsContext, ConnectionEndReason.InvalidRequestHeaders); 231KestrelMetrics.AddConnectionEndReason(_context.MetricsContext, ConnectionEndReason.UnexpectedEndOfRequestContent);
Internal\Http\Http1OutputProducer.cs (1)
461public void Abort(ConnectionAbortedException error, ConnectionEndReason reason)
Internal\Http\HttpProtocol.cs (9)
669DisableKeepAlive(ConnectionEndReason.RequestNoKeepAlive); 870DisableKeepAlive(ConnectionEndReason.ResponseContentLengthMismatch); 923DisableKeepAlive(ConnectionEndReason.ResponseContentLengthMismatch); 1042DisableKeepAlive(ConnectionEndReason.ErrorAfterStartingResponse); 1149DisableKeepAlive(ConnectionEndReason.ResponseNoKeepAlive); 1160DisableKeepAlive(ConnectionEndReason.ResponseNoKeepAlive); 1196DisableKeepAlive(ConnectionEndReason.ResponseNoKeepAlive); 1226DisableKeepAlive(ConnectionEndReason.ResponseNoKeepAlive); 1421internal virtual void DisableKeepAlive(ConnectionEndReason reason)
Internal\Http\IHttpOutputAborter.cs (1)
10void Abort(ConnectionAbortedException abortReason, ConnectionEndReason reason);
Internal\Http2\FlowControl\InputFlowControl.cs (1)
56throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorFlowControlWindowExceeded, Http2ErrorCode.FLOW_CONTROL_ERROR, ConnectionEndReason.FlowControlWindowExceeded);
Internal\Http2\Http2Connection.cs (63)
143private ConnectionEndReason _gracefulCloseReason; 229SetConnectionErrorCode(hasActiveStreams ? ConnectionEndReason.ConnectionReset : ConnectionEndReason.TransportCompleted, Http2ErrorCode.NO_ERROR); 235private void SetConnectionErrorCode(ConnectionEndReason reason, Http2ErrorCode errorCode) 242public void Abort(ConnectionAbortedException ex, ConnectionEndReason reason) 247public void Abort(ConnectionAbortedException ex, Http2ErrorCode errorCode, ConnectionEndReason reason) 258public void StopProcessingNextRequest(ConnectionEndReason reason) 264Abort(new ConnectionAbortedException(CoreStrings.BadRequest_RequestHeadersTimeout), Http2ErrorCode.INTERNAL_ERROR, ConnectionEndReason.RequestHeadersTimeout); 272Abort(new ConnectionAbortedException(CoreStrings.BadRequest_RequestBodyTimeout), Http2ErrorCode.INTERNAL_ERROR, ConnectionEndReason.MinRequestBodyDataRate); 275public void StopProcessingNextRequest(bool serverInitiated, ConnectionEndReason reason) 290var reason = ConnectionEndReason.Unset; 301reason = ConnectionEndReason.TransportCompleted; 361reason = ConnectionEndReason.TransportCompleted; 378throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorKeepAliveTimeout, Http2ErrorCode.INTERNAL_ERROR, ConnectionEndReason.KeepAliveTimeout); 396reason = ConnectionEndReason.ConnectionReset; 400reason = ConnectionEndReason.TransportCompleted; 409reason = ConnectionEndReason.IOError; 430reason = ConnectionEndReason.ErrorReadingHeaders; 437reason = ConnectionEndReason.OtherError; 513throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorMinTlsVersion(tlsFeature.Protocol), Http2ErrorCode.INADEQUATE_SECURITY, ConnectionEndReason.InsufficientTlsVersion); 598SetConnectionErrorCode(ConnectionEndReason.InvalidHttpVersion, Http2ErrorCode.PROTOCOL_ERROR); 613throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorInvalidPreface, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidHandshake); 685throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamIdEven(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidStreamId); 695Http2FrameType.PUSH_PROMISE => throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorPushPromiseReceived, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.UnexpectedFrame), 718throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorPaddingTooLong(_incomingFrame.Type), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidDataPadding); 740throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamHalfClosedRemote(_incomingFrame.Type, stream.StreamId), Http2ErrorCode.STREAM_CLOSED, ConnectionEndReason.FrameAfterStreamClose); 757throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamClosed(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.STREAM_CLOSED, ConnectionEndReason.UnknownStream); 762return new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamAborted(_incomingFrame.Type, stream.StreamId), Http2ErrorCode.STREAM_CLOSED, ConnectionEndReason.FrameAfterStreamClose); 767return new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamIdZero(_incomingFrame.Type), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidStreamId); 772return new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamIdNotZero(_incomingFrame.Type), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidStreamId); 778return new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorHeadersInterleaved(_incomingFrame.Type, _incomingFrame.StreamId, _currentHeadersStream.StreamId), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.UnexpectedFrame); 783return new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorUnexpectedFrameLength(_incomingFrame.Type, expectedLength), Http2ErrorCode.FRAME_SIZE_ERROR, ConnectionEndReason.InvalidFrameLength); 800throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorPaddingTooLong(_incomingFrame.Type), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidDataPadding); 805throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamSelfDependency(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.StreamSelfDependency); 825throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamHalfClosedRemote(_incomingFrame.Type, stream.StreamId), Http2ErrorCode.STREAM_CLOSED, ConnectionEndReason.FrameAfterStreamClose); 831throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorHeadersWithTrailersNoEndStream, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.MissingStreamEnd); 850throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamClosed(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.STREAM_CLOSED, ConnectionEndReason.InvalidStreamId); 928throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamSelfDependency(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.StreamSelfDependency); 995throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorSettingsAckLengthNotZero, Http2ErrorCode.FRAME_SIZE_ERROR, ConnectionEndReason.InvalidFrameLength); 1003throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorSettingsLengthNotMultipleOfSix, Http2ErrorCode.FRAME_SIZE_ERROR, ConnectionEndReason.InvalidFrameLength); 1037throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorInitialWindowSizeInvalid, Http2ErrorCode.FLOW_CONTROL_ERROR, ConnectionEndReason.InvalidSettings); 1059throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorSettingsParameterOutOfRange(ex.Parameter), errorCode, ConnectionEndReason.InvalidSettings); 1110StopProcessingNextRequest(serverInitiated: false, ConnectionEndReason.ClientGoAway); 1147throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorWindowUpdateIncrementZero, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidWindowUpdateSize); 1154throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorWindowUpdateSizeInvalid, Http2ErrorCode.FLOW_CONTROL_ERROR, ConnectionEndReason.InvalidWindowUpdateSize); 1184throw new Http2ConnectionErrorException(CoreStrings.Http2ErrorContinuationWithNoHeaders, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.UnexpectedFrame); 1322Abort(new ConnectionAbortedException(CoreStrings.Http2ConnectionFaulted), Http2ErrorCode.ENHANCE_YOUR_CALM, ConnectionEndReason.StreamResetLimitExceeded); 1324throw new Http2ConnectionErrorException(CoreStrings.Http2ConnectionFaulted, Http2ErrorCode.ENHANCE_YOUR_CALM, ConnectionEndReason.StreamResetLimitExceeded); 1383throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamIdle(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidStreamId); 1439throw new Http2ConnectionErrorException(CoreStrings.FormatHttp2ErrorStreamClosed(_incomingFrame.Type, _incomingFrame.StreamId), Http2ErrorCode.STREAM_CLOSED, ConnectionEndReason.FrameAfterStreamClose); 1583throw new Http2ConnectionErrorException(CoreStrings.BadRequest_HeadersExceedMaxTotalSize, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.MaxRequestHeadersTotalSizeExceeded); 1645throw new Http2ConnectionErrorException(bre.Message, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.MaxRequestHeaderCountExceeded); 1650throw new Http2ConnectionErrorException(bre.Message, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1654throw new Http2ConnectionErrorException(CoreStrings.BadRequest_MalformedRequestInvalidHeaders, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1665throw new Http2ConnectionErrorException(CoreStrings.HttpErrorConnectionSpecificHeaderField, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1676throw new Http2ConnectionErrorException(CoreStrings.HttpErrorTrailerNameUppercase, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1680throw new Http2ConnectionErrorException(CoreStrings.HttpErrorHeaderNameUppercase, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1709throw new Http2ConnectionErrorException(CoreStrings.HttpErrorPseudoHeaderFieldAfterRegularHeaders, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1715throw new Http2ConnectionErrorException(CoreStrings.HttpErrorTrailersContainPseudoHeaderField, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1724throw new Http2ConnectionErrorException(CoreStrings.HttpErrorUnknownPseudoHeaderField, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1731throw new Http2ConnectionErrorException(CoreStrings.HttpErrorResponsePseudoHeaderField, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders); 1738throw new Http2ConnectionErrorException(CoreStrings.HttpErrorDuplicatePseudoHeaderField, Http2ErrorCode.PROTOCOL_ERROR, ConnectionEndReason.InvalidRequestHeaders);
Internal\Http2\Http2FrameWriter.cs (6)
172_http2Connection.Abort(ex, Http2ErrorCode.INTERNAL_ERROR, ConnectionEndReason.OutputQueueSizeExceeded); 352const ConnectionEndReason reason = ConnectionEndReason.InvalidWindowUpdateSize; 559_http2Connection.Abort(new ConnectionAbortedException(ex.Message, ex), Http2ErrorCode.INTERNAL_ERROR, ConnectionEndReason.ErrorWritingHeaders); 600_http2Connection.Abort(new ConnectionAbortedException(ex.Message, ex), Http2ErrorCode.INTERNAL_ERROR, ConnectionEndReason.ErrorWritingHeaders); 1131_http2Connection.Abort(new ConnectionAbortedException("HTTP/2 connection exceeded the outgoing flow control maximum queue size."), Http2ErrorCode.INTERNAL_ERROR, ConnectionEndReason.FlowControlQueueSizeExceeded);
Internal\Http2\Http2OutputProducer.cs (1)
251void IHttpOutputAborter.Abort(ConnectionAbortedException abortReason, ConnectionEndReason reason)
Internal\Http3\Http3Connection.cs (21)
48private ConnectionEndReason _gracefulCloseReason; 107public void StopProcessingNextRequest(ConnectionEndReason reason) 110public void StopProcessingNextRequest(bool serverInitiated, ConnectionEndReason reason) 157public void Abort(ConnectionAbortedException ex, ConnectionEndReason reason) 162public void Abort(ConnectionAbortedException ex, Http3ErrorCode errorCode, ConnectionEndReason reason) 244connection.OnStreamConnectionError(new Http3ConnectionErrorException(CoreStrings.Http3ErrorControlStreamClosed, Http3ErrorCode.ClosedCriticalStream, ConnectionEndReason.ClosedCriticalStream)); 322OnStreamConnectionError(new Http3ConnectionErrorException(CoreStrings.ConnectionTimedBecauseResponseMininumDataRateNotSatisfied, Http3ErrorCode.InternalError, ConnectionEndReason.MinResponseDataRate)); 345ConnectionEndReason reason = ConnectionEndReason.Unset; 469reason = ConnectionEndReason.ConnectionReset; 479reason = ConnectionEndReason.IOError; 485reason = ConnectionEndReason.OtherError; 496reason = ConnectionEndReason.OtherError; 548if (reason == ConnectionEndReason.Unset && _gracefulCloseReason != ConnectionEndReason.Unset) 566Abort(CreateConnectionAbortError(error, clientAbort), Http3ErrorCode.InternalError, ConnectionEndReason.OtherError); 727var connectionError = new Http3ConnectionErrorException(CoreStrings.Http3ControlStreamErrorInitializingOutbound, Http3ErrorCode.ClosedCriticalStream, ConnectionEndReason.ClosedCriticalStream); 731Abort(new ConnectionAbortedException(connectionError.Message, connectionError), connectionError.ErrorCode, ConnectionEndReason.ClosedCriticalStream); 897Abort(new ConnectionAbortedException(CoreStrings.BadRequest_RequestHeadersTimeout), ConnectionEndReason.RequestHeadersTimeout); 905Abort(new ConnectionAbortedException(CoreStrings.BadRequest_RequestBodyTimeout), ConnectionEndReason.MinRequestBodyDataRate); 913Abort(new ConnectionAbortedException(CoreStrings.ConnectionAbortedByClient), Http3ErrorCodeOrNoError, ConnectionEndReason.TransportCompleted);
Internal\Http3\Http3ConnectionErrorException.cs (2)
10public Http3ConnectionErrorException(string message, Http3ErrorCode errorCode, ConnectionEndReason reason) 18public ConnectionEndReason Reason { get; }
Internal\Http3\Http3ControlStream.cs (8)
205throw new Http3ConnectionErrorException(CoreStrings.FormatHttp3ControlStreamErrorMultipleInboundStreams("control"), Http3ErrorCode.StreamCreationError, ConnectionEndReason.StreamCreationError); 214throw new Http3ConnectionErrorException(CoreStrings.FormatHttp3ControlStreamErrorMultipleInboundStreams("encoder"), Http3ErrorCode.StreamCreationError, ConnectionEndReason.StreamCreationError); 223throw new Http3ConnectionErrorException(CoreStrings.FormatHttp3ControlStreamErrorMultipleInboundStreams("decoder"), Http3ErrorCode.StreamCreationError, ConnectionEndReason.StreamCreationError); 305throw new Http3ConnectionErrorException(CoreStrings.FormatHttp3ErrorUnsupportedFrameOnControlStream(_incomingFrame.FormattedType), Http3ErrorCode.UnexpectedFrame, ConnectionEndReason.UnexpectedFrame); 324throw new Http3ConnectionErrorException(CoreStrings.Http3ErrorControlStreamMultipleSettingsFrames, Http3ErrorCode.UnexpectedFrame, ConnectionEndReason.UnexpectedFrame); 370throw new Http3ConnectionErrorException(message, Http3ErrorCode.SettingsError, ConnectionEndReason.InvalidSettings); 390_context.Connection.StopProcessingNextRequest(serverInitiated: false, ConnectionEndReason.ClientGoAway); 434throw new Http3ConnectionErrorException(message, Http3ErrorCode.MissingSettings, ConnectionEndReason.InvalidSettings);
Internal\Http3\Http3OutputProducer.cs (1)
110void IHttpOutputAborter.Abort(ConnectionAbortedException abortReason, ConnectionEndReason reason)
Internal\Http3\Http3Stream.cs (5)
763CoreStrings.FormatHttp3ErrorUnsupportedFrameOnRequestStream(_incomingFrame.FormattedType), Http3ErrorCode.UnexpectedFrame, ConnectionEndReason.UnexpectedFrame), 766CoreStrings.FormatHttp3ErrorUnsupportedFrameOnServer(_incomingFrame.FormattedType), Http3ErrorCode.UnexpectedFrame, ConnectionEndReason.UnexpectedFrame), 784throw new Http3ConnectionErrorException(CoreStrings.FormatHttp3StreamErrorFrameReceivedAfterTrailers(Http3Formatting.ToFormattedType(Http3FrameType.Headers)), Http3ErrorCode.UnexpectedFrame, ConnectionEndReason.UnexpectedFrame); 883throw new Http3ConnectionErrorException(CoreStrings.Http3StreamErrorDataReceivedBeforeHeaders, Http3ErrorCode.UnexpectedFrame, ConnectionEndReason.UnexpectedFrame); 891throw new Http3ConnectionErrorException(message, Http3ErrorCode.UnexpectedFrame, ConnectionEndReason.UnexpectedFrame);
Internal\HttpConnection.cs (6)
114using var shutdownRegistration = connectionLifetimeNotificationFeature?.ConnectionClosedRequested.Register(state => ((HttpConnection)state!).StopProcessingNextRequest(ConnectionEndReason.GracefulAppShutdown), this); 153private void StopProcessingNextRequest(ConnectionEndReason reason) 191private void Abort(ConnectionAbortedException ex, ConnectionEndReason reason) 281_requestProcessor!.StopProcessingNextRequest(ConnectionEndReason.KeepAliveTimeout); 291Abort(new ConnectionAbortedException(CoreStrings.ConnectionTimedBecauseResponseMininumDataRateNotSatisfied), ConnectionEndReason.MinResponseDataRate); 295Abort(new ConnectionAbortedException(CoreStrings.ConnectionTimedOutByServer), ConnectionEndReason.ServerTimeout);
Internal\Infrastructure\ConnectionMetricsContext.cs (1)
18public ConnectionEndReason? ConnectionEndReason { get; set; }
Internal\Infrastructure\KestrelMetrics.cs (58)
149AddConnectionEndReason(metricsContext, ConnectionEndReason.MaxConcurrentConnectionsExceeded); 420public static void AddConnectionEndReason(IConnectionMetricsTagsFeature? feature, ConnectionEndReason reason) 422Debug.Assert(reason != ConnectionEndReason.Unset); 433public static void AddConnectionEndReason(ConnectionMetricsContext? context, ConnectionEndReason reason, bool overwrite = false) 435Debug.Assert(reason != ConnectionEndReason.Unset); 459internal static string? GetErrorType(ConnectionEndReason reason) 465internal static bool TryGetErrorType(ConnectionEndReason reason, [NotNullWhen(true)]out string? errorTypeValue) 469ConnectionEndReason.Unset => null, // Not an error 470ConnectionEndReason.ClientGoAway => null, // Not an error 471ConnectionEndReason.TransportCompleted => null, // Not an error 472ConnectionEndReason.GracefulAppShutdown => null, // Not an error 473ConnectionEndReason.RequestNoKeepAlive => null, // Not an error 474ConnectionEndReason.ResponseNoKeepAlive => null, // Not an error 475ConnectionEndReason.ErrorAfterStartingResponse => "error_after_starting_response", 476ConnectionEndReason.ConnectionReset => "connection_reset", 477ConnectionEndReason.FlowControlWindowExceeded => "flow_control_window_exceeded", 478ConnectionEndReason.KeepAliveTimeout => "keep_alive_timeout", 479ConnectionEndReason.InsufficientTlsVersion => "insufficient_tls_version", 480ConnectionEndReason.InvalidHandshake => "invalid_handshake", 481ConnectionEndReason.InvalidStreamId => "invalid_stream_id", 482ConnectionEndReason.FrameAfterStreamClose => "frame_after_stream_close", 483ConnectionEndReason.UnknownStream => "unknown_stream", 484ConnectionEndReason.UnexpectedFrame => "unexpected_frame", 485ConnectionEndReason.InvalidFrameLength => "invalid_frame_length", 486ConnectionEndReason.InvalidDataPadding => "invalid_data_padding", 487ConnectionEndReason.InvalidRequestHeaders => "invalid_request_headers", 488ConnectionEndReason.StreamResetLimitExceeded => "stream_reset_limit_exceeded", 489ConnectionEndReason.InvalidWindowUpdateSize => "invalid_window_update_size", 490ConnectionEndReason.StreamSelfDependency => "stream_self_dependency", 491ConnectionEndReason.InvalidSettings => "invalid_settings", 492ConnectionEndReason.MissingStreamEnd => "missing_stream_end", 493ConnectionEndReason.MaxFrameLengthExceeded => "max_frame_length_exceeded", 494ConnectionEndReason.ErrorReadingHeaders => "error_reading_headers", 495ConnectionEndReason.ErrorWritingHeaders => "error_writing_headers", 496ConnectionEndReason.OtherError => "other_error", 497ConnectionEndReason.InvalidHttpVersion => "invalid_http_version", 498ConnectionEndReason.RequestHeadersTimeout => "request_headers_timeout", 499ConnectionEndReason.MinRequestBodyDataRate => "min_request_body_data_rate", 500ConnectionEndReason.MinResponseDataRate => "min_response_data_rate", 501ConnectionEndReason.FlowControlQueueSizeExceeded => "flow_control_queue_size_exceeded", 502ConnectionEndReason.OutputQueueSizeExceeded => "output_queue_size_exceeded", 503ConnectionEndReason.ClosedCriticalStream => "closed_critical_stream", 504ConnectionEndReason.AbortedByApp => "aborted_by_app", 505ConnectionEndReason.WriteCanceled => "write_canceled", 506ConnectionEndReason.InvalidBodyReaderState => "invalid_body_reader_state", 507ConnectionEndReason.ServerTimeout => "server_timeout", 508ConnectionEndReason.StreamCreationError => "stream_creation_error", 509ConnectionEndReason.IOError => "io_error", 510ConnectionEndReason.AppShutdownTimeout => "app_shutdown_timeout", 511ConnectionEndReason.TlsHandshakeFailed => "tls_handshake_failed", 512ConnectionEndReason.InvalidRequestLine => "invalid_request_line", 513ConnectionEndReason.TlsNotSupported => "tls_not_supported", 514ConnectionEndReason.MaxRequestBodySizeExceeded => "max_request_body_size_exceeded", 515ConnectionEndReason.UnexpectedEndOfRequestContent => "unexpected_end_of_request_content", 516ConnectionEndReason.MaxConcurrentConnectionsExceeded => "max_concurrent_connections_exceeded", 517ConnectionEndReason.MaxRequestHeadersTotalSizeExceeded => "max_request_headers_total_size_exceeded", 518ConnectionEndReason.MaxRequestHeaderCountExceeded => "max_request_header_count_exceeded", 519ConnectionEndReason.ResponseContentLengthMismatch => "response_content_length_mismatch",
Internal\Infrastructure\PipeWriterHelpers\TimingPipeFlusher.cs (1)
95outputAborter.Abort(new ConnectionAbortedException(CoreStrings.ConnectionOrStreamAbortedByCancellationToken, ex), ConnectionEndReason.WriteCanceled);
Internal\Infrastructure\TransportConnectionManager.cs (1)
83ConnectionEndReason.AppShutdownTimeout, overwrite: true);
Internal\IRequestProcessor.cs (2)
12void StopProcessingNextRequest(ConnectionEndReason reason); 17void Abort(ConnectionAbortedException ex, ConnectionEndReason reason);
Middleware\HttpsConnectionMiddleware.cs (1)
244KestrelMetrics.AddConnectionEndReason(metricsTagsFeature, ConnectionEndReason.TlsHandshakeFailed);
src\Shared\ServerInfrastructure\Http2\Http2ConnectionErrorException.cs (2)
10public Http2ConnectionErrorException(string message, Http2ErrorCode errorCode, ConnectionEndReason reason) 18public ConnectionEndReason Reason { get; }
src\Shared\ServerInfrastructure\Http2\Http2FrameReader.cs (2)
54throw new Http2ConnectionErrorException(SharedStrings.FormatHttp2ErrorFrameOverLimit(payloadLength, maxFrameSize), Http2ErrorCode.FRAME_SIZE_ERROR, ConnectionEndReason.MaxFrameLengthExceeded); 86SharedStrings.FormatHttp2ErrorUnexpectedFrameLength(frame.Type, expectedLength: extendedHeaderLength), Http2ErrorCode.FRAME_SIZE_ERROR, ConnectionEndReason.InvalidFrameLength);