public final class HttpMetric extends Object
Http2Metric
for metrics that are only available
on HTTP/2 operations.Modifier and Type | Field and Description |
---|---|
static SdkMetric<Integer> |
AVAILABLE_CONCURRENCY
The number of additional concurrent requests that can be supported by the HTTP client without needing to establish
additional connections to the target server.
|
static SdkMetric<Duration> |
CONCURRENCY_ACQUIRE_DURATION
The time taken to acquire a channel from the connection pool.
|
static SdkMetric<String> |
HTTP_CLIENT_NAME
The name of the HTTP client.
|
static SdkMetric<Integer> |
HTTP_STATUS_CODE
The status code of the HTTP response.
|
static SdkMetric<Integer> |
LEASED_CONCURRENCY
The number of requests that are currently being executed by the HTTP client.
|
static SdkMetric<Integer> |
MAX_CONCURRENCY
The maximum number of concurrent requests that is supported by the HTTP client.
|
static SdkMetric<Integer> |
PENDING_CONCURRENCY_ACQUIRES
The number of requests that are awaiting concurrency to be made available from the HTTP client.
|
public static final SdkMetric<String> HTTP_CLIENT_NAME
public static final SdkMetric<Integer> MAX_CONCURRENCY
For HTTP/1 operations, this is equal to the maximum number of TCP connections that can be be pooled by the HTTP client. For HTTP/2 operations, this is equal to the maximum number of streams that can be pooled by the HTTP client.
Note: Depending on the HTTP client, this is either a value for all endpoints served by the HTTP client, or a value that applies only to the specific endpoint/host used in the request. For 'apache-http-client', this value is for the entire HTTP client. For 'netty-nio-client', this value is per-endpoint. In all cases, this value is scoped to an individual HTTP client instance, and does not include concurrency that may be available in other HTTP clients running within the same JVM.
public static final SdkMetric<Integer> AVAILABLE_CONCURRENCY
For HTTP/1 operations, this is equal to the number of TCP connections that have been established with the service, but are currently idle/unused. For HTTP/2 operations, this is equal to the number of streams that are currently idle/unused.
Note: Depending on the HTTP client, this is either a value for all endpoints served by the HTTP client, or a value that applies only to the specific endpoint/host used in the request. For 'apache-http-client', this value is for the entire HTTP client. For 'netty-nio-client', this value is per-endpoint. In all cases, this value is scoped to an individual HTTP client instance, and does not include concurrency that may be available in other HTTP clients running within the same JVM.
public static final SdkMetric<Integer> LEASED_CONCURRENCY
For HTTP/1 operations, this is equal to the number of TCP connections currently in active communication with the service (excluding idle connections). For HTTP/2 operations, this is equal to the number of HTTP streams currently in active communication with the service (excluding idle stream capacity).
Note: Depending on the HTTP client, this is either a value for all endpoints served by the HTTP client, or a value that applies only to the specific endpoint/host used in the request. For 'apache-http-client', this value is for the entire HTTP client. For 'netty-nio-client', this value is per-endpoint. In all cases, this value is scoped to an individual HTTP client instance, and does not include concurrency that may be available in other HTTP clients running within the same JVM.
public static final SdkMetric<Integer> PENDING_CONCURRENCY_ACQUIRES
For HTTP/1 operations, this is equal to the number of requests currently blocked, waiting for a TCP connection to be established or returned from the connection pool. For HTTP/2 operations, this is equal to the number of requests currently blocked, waiting for a new stream (and possibly a new HTTP/2 connection) from the connection pool.
Note: Depending on the HTTP client, this is either a value for all endpoints served by the HTTP client, or a value that applies only to the specific endpoint/host used in the request. For 'apache-http-client', this value is for the entire HTTP client. For 'netty-nio-client', this value is per-endpoint. In all cases, this value is scoped to an individual HTTP client instance, and does not include concurrency that may be available in other HTTP clients running within the same JVM.
public static final SdkMetric<Integer> HTTP_STATUS_CODE
This is reported by the SDK core, and should not be reported by an individual HTTP client implementation.
public static final SdkMetric<Duration> CONCURRENCY_ACQUIRE_DURATION
For HTTP/1 operations, a channel is equivalent to a TCP connection. For HTTP/2 operations, a channel is equivalent to an HTTP/2 stream channel. For both protocols, the time to acquire a new channel may include the following:
Copyright © 2022. All rights reserved.