Package io.vertx.core.spi.metrics
Interface HttpClientMetrics<R,W,S>
-
- All Superinterfaces:
Metrics
,NetworkMetrics<S>
,TCPMetrics<S>
public interface HttpClientMetrics<R,W,S> extends TCPMetrics<S>
The http client metrics SPI that Vert.x will use to call when http client events occur. The thread model for the http server metrics depends on the actual context thats started the server.Event loop context
Unless specified otherwise, all the methods on this object including the methods inherited from the super interfaces are invoked with the thread of the http client and therefore are the same than theVertxMetrics
createMetrics
method that created and returned this metrics object.Worker context
Unless specified otherwise, all the methods on this object including the methods inherited from the super interfaces are invoked with a worker thread.- Author:
- Nick Scavelli
-
-
Field Summary
-
Fields inherited from interface io.vertx.core.spi.metrics.Metrics
METRICS_ENABLED
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default W
connected(WebSocket webSocket)
Called when a web socket connects.default ClientMetrics<R,HttpRequest,HttpResponse>
createEndpointMetrics(SocketAddress remoteAddress, int maxPoolSize)
Provides metrics for a particular endpointdefault void
disconnected(W webSocketMetric)
Called when the web socket has disconnected.default void
endpointConnected(ClientMetrics<R,?,?> endpointMetric)
Called when a connection is made to a endpoint.default void
endpointDisconnected(ClientMetrics<R,?,?> endpointMetric)
Called when a connection to an endpoint is closed.-
Methods inherited from interface io.vertx.core.spi.metrics.NetworkMetrics
bytesRead, bytesWritten, exceptionOccurred
-
Methods inherited from interface io.vertx.core.spi.metrics.TCPMetrics
connected, disconnected
-
-
-
-
Method Detail
-
createEndpointMetrics
default ClientMetrics<R,HttpRequest,HttpResponse> createEndpointMetrics(SocketAddress remoteAddress, int maxPoolSize)
Provides metrics for a particular endpoint- Parameters:
remoteAddress
- the endpoint remote addressmaxPoolSize
- the client max pool size- Returns:
- the endpoint metric
-
endpointConnected
default void endpointConnected(ClientMetrics<R,?,?> endpointMetric)
Called when a connection is made to a endpoint.- Parameters:
endpointMetric
- the endpoint metric
-
endpointDisconnected
default void endpointDisconnected(ClientMetrics<R,?,?> endpointMetric)
Called when a connection to an endpoint is closed.- Parameters:
endpointMetric
- the endpoint metric
-
connected
default W connected(WebSocket webSocket)
Called when a web socket connects.- Parameters:
webSocket
- the server web socket- Returns:
- the web socket metric
-
disconnected
default void disconnected(W webSocketMetric)
Called when the web socket has disconnected.- Parameters:
webSocketMetric
- the web socket metric
-
-