Interface IHttpTelemetryConsumer
A consumer of System.Net.Http EventSource events.
Namespace: Yarp.Telemetry.Consumption
Assembly: Yarp.Telemetry.Consumption.dll
Syntax
public interface IHttpTelemetryConsumer
Methods
| Improve this Doc View SourceOnConnectionClosed(DateTime, Int32, Int32)
Called when a new HTTP connection is closed.
Declaration
virtual void OnConnectionClosed(DateTime timestamp, int versionMajor, int versionMinor)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
System.Int32 | versionMajor | Major component of the connection's HTTP version. |
System.Int32 | versionMinor | Minor component of the connection's HTTP version. |
OnConnectionEstablished(DateTime, Int32, Int32)
Called when a new HTTP connection is established.
Declaration
virtual void OnConnectionEstablished(DateTime timestamp, int versionMajor, int versionMinor)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
System.Int32 | versionMajor | Major component of the connection's HTTP version. |
System.Int32 | versionMinor | Minor component of the connection's HTTP version. |
OnRequestContentStart(DateTime)
Called before sending the request content.
Declaration
virtual void OnRequestContentStart(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
OnRequestContentStop(DateTime, Int64)
Called after sending the request content.
Declaration
virtual void OnRequestContentStop(DateTime timestamp, long contentLength)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
System.Int64 | contentLength |
OnRequestFailed(DateTime)
Called before OnRequestStop(DateTime) if the request failed.
Declaration
virtual void OnRequestFailed(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
OnRequestHeadersStart(DateTime)
Called before sending the request headers.
Declaration
virtual void OnRequestHeadersStart(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
OnRequestHeadersStop(DateTime)
Called after sending the request headers.
Declaration
virtual void OnRequestHeadersStop(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
OnRequestLeftQueue(DateTime, TimeSpan, Int32, Int32)
Called when a request that hit the MaxConnectionsPerServer or MAX_CONCURRENT_STREAMS limit leaves the queue.
Declaration
virtual void OnRequestLeftQueue(DateTime timestamp, TimeSpan timeOnQueue, int versionMajor, int versionMinor)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
TimeSpan | timeOnQueue | Time spent on queue. |
System.Int32 | versionMajor | Major component of the request's HTTP version. |
System.Int32 | versionMinor | Minor component of the request's HTTP version. |
OnRequestStart(DateTime, String, String, Int32, String, Int32, Int32, HttpVersionPolicy)
Called before an HTTP request.
Declaration
virtual void OnRequestStart(DateTime timestamp, string scheme, string host, int port, string pathAndQuery, int versionMajor, int versionMinor, HttpVersionPolicy versionPolicy)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
System.String | scheme | Scheme of the request Uri. |
System.String | host | Host of the request Uri. |
System.Int32 | port | Port of the request Uri. |
System.String | pathAndQuery | Path and query of the request Uri. |
System.Int32 | versionMajor | Major component of the request's HTTP version. |
System.Int32 | versionMinor | Minor component of the request's HTTP version. |
HttpVersionPolicy | versionPolicy |
OnRequestStop(DateTime)
Called after an HTTP request.
Declaration
virtual void OnRequestStop(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
OnResponseContentStart(DateTime)
Called when
Declaration
virtual void OnResponseContentStart(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
OnResponseContentStop(DateTime)
Called when
Declaration
virtual void OnResponseContentStop(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
OnResponseHeadersStart(DateTime)
Called before reading the response headers.
Declaration
virtual void OnResponseHeadersStart(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |
OnResponseHeadersStop(DateTime)
Called after reading all response headers.
Declaration
virtual void OnResponseHeadersStop(DateTime timestamp)
Parameters
Type | Name | Description |
---|---|---|
DateTime | timestamp | Timestamp when the event was fired. |