public final class HttpClientEventPublisher extends HttpClientEventsListener implements io.reactivex.netty.events.EventSource<HttpClientEventsListener>, io.reactivex.netty.events.EventPublisher
| Constructor and Description |
|---|
HttpClientEventPublisher() |
| Modifier and Type | Method and Description |
|---|---|
io.reactivex.netty.events.EventSource<io.reactivex.netty.protocol.tcp.client.events.TcpClientEventListener> |
asTcpEventSource() |
HttpClientEventPublisher |
copy() |
void |
onByteRead(long bytesRead) |
void |
onByteWritten(long bytesWritten) |
void |
onConnectFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable) |
void |
onConnectionCloseFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable) |
void |
onConnectionCloseStart() |
void |
onConnectionCloseSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit) |
void |
onConnectStart() |
void |
onConnectSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit) |
void |
onCustomEvent(java.lang.Object event) |
void |
onCustomEvent(java.lang.Object event,
long duration,
java.util.concurrent.TimeUnit timeUnit) |
void |
onCustomEvent(java.lang.Object event,
long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable) |
void |
onCustomEvent(java.lang.Object event,
java.lang.Throwable throwable) |
void |
onFlushComplete(long duration,
java.util.concurrent.TimeUnit timeUnit) |
void |
onFlushStart() |
void |
onPoolAcquireFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable) |
void |
onPoolAcquireStart() |
void |
onPoolAcquireSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit) |
void |
onPooledConnectionEviction() |
void |
onPooledConnectionReuse() |
void |
onPoolReleaseFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable) |
void |
onPoolReleaseStart() |
void |
onPoolReleaseSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit) |
void |
onRequestProcessingComplete(long duration,
java.util.concurrent.TimeUnit timeUnit)
Event when the entire request processing (request header write to response failed/complete) is completed.
|
void |
onRequestSubmitted()
Event when a new request is submitted for the client.
|
void |
onRequestWriteComplete(long duration,
java.util.concurrent.TimeUnit timeUnit)
Event when a request write is completed.
|
void |
onRequestWriteFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable)
Event when a request write failed.
|
void |
onRequestWriteStart()
Event when the write of request started.
|
void |
onResponseContentReceived()
Event whenever an HTTP response content is received (an HTTP response can have multiple content chunks, in which
case this event will be fired as many times for the same response).
|
void |
onResponseFailed(java.lang.Throwable throwable)
Event when the response failed (either it did not arrive or not arrived completely)
|
void |
onResponseHeadersReceived(int responseCode,
long duration,
java.util.concurrent.TimeUnit timeUnit)
Event when the response headers are received.
|
void |
onResponseReceiveComplete(long duration,
java.util.concurrent.TimeUnit timeUnit)
Event when the response receive is completed.
|
void |
onWriteFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable) |
void |
onWriteStart() |
void |
onWriteSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit) |
boolean |
publishingEnabled() |
rx.Subscription |
subscribe(HttpClientEventsListener listener) |
public void onRequestSubmitted()
HttpClientEventsListeneronRequestSubmitted in class HttpClientEventsListenerpublic void onRequestWriteStart()
HttpClientEventsListeneronRequestWriteStart in class HttpClientEventsListenerpublic void onRequestWriteComplete(long duration,
java.util.concurrent.TimeUnit timeUnit)
HttpClientEventsListeneronRequestWriteComplete in class HttpClientEventsListenerduration - Time taken from the start of write to completion.timeUnit - Time unit for the duration.public void onRequestWriteFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable)
HttpClientEventsListeneronRequestWriteFailed in class HttpClientEventsListenerduration - Time taken from the start of write to failure.timeUnit - Time unit for the duration.throwable - Error that caused the failure.public void onResponseHeadersReceived(int responseCode,
long duration,
java.util.concurrent.TimeUnit timeUnit)
HttpClientEventsListeneronResponseHeadersReceived in class HttpClientEventsListenerresponseCode - The HTTP response code.duration - The time between the request write completion and response header recieve.timeUnit - Timeunit for the duration.public void onResponseContentReceived()
HttpClientEventsListeneronResponseContentReceived in class HttpClientEventsListenerpublic void onResponseReceiveComplete(long duration,
java.util.concurrent.TimeUnit timeUnit)
HttpClientEventsListeneronResponseReceiveComplete in class HttpClientEventsListenerduration - Time taken between receiving the response headers and completion of response.timeUnit - Time unit for the duration.public void onResponseFailed(java.lang.Throwable throwable)
HttpClientEventsListeneronResponseFailed in class HttpClientEventsListenerthrowable - Error that caused the failure.public void onRequestProcessingComplete(long duration,
java.util.concurrent.TimeUnit timeUnit)
HttpClientEventsListeneronRequestProcessingComplete in class HttpClientEventsListenerduration - Time taken from start of write of request to response receive completion.timeUnit - Time unit for the duration.public void onConnectionCloseFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable)
onConnectionCloseFailed in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onConnectStart()
onConnectStart in class io.reactivex.netty.client.events.ClientEventListenerpublic void onConnectSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit)
onConnectSuccess in class io.reactivex.netty.client.events.ClientEventListenerpublic void onConnectFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable)
onConnectFailed in class io.reactivex.netty.client.events.ClientEventListenerpublic void onPoolReleaseStart()
onPoolReleaseStart in class io.reactivex.netty.client.events.ClientEventListenerpublic void onPoolReleaseSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit)
onPoolReleaseSuccess in class io.reactivex.netty.client.events.ClientEventListenerpublic void onPoolReleaseFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable)
onPoolReleaseFailed in class io.reactivex.netty.client.events.ClientEventListenerpublic void onPooledConnectionEviction()
onPooledConnectionEviction in class io.reactivex.netty.client.events.ClientEventListenerpublic void onPooledConnectionReuse()
onPooledConnectionReuse in class io.reactivex.netty.client.events.ClientEventListenerpublic void onPoolAcquireStart()
onPoolAcquireStart in class io.reactivex.netty.client.events.ClientEventListenerpublic void onPoolAcquireSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit)
onPoolAcquireSuccess in class io.reactivex.netty.client.events.ClientEventListenerpublic void onPoolAcquireFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable)
onPoolAcquireFailed in class io.reactivex.netty.client.events.ClientEventListenerpublic void onByteRead(long bytesRead)
onByteRead in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onByteWritten(long bytesWritten)
onByteWritten in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onFlushStart()
onFlushStart in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onFlushComplete(long duration,
java.util.concurrent.TimeUnit timeUnit)
onFlushComplete in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onWriteStart()
onWriteStart in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onWriteSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit)
onWriteSuccess in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onWriteFailed(long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable)
onWriteFailed in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onConnectionCloseStart()
onConnectionCloseStart in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onConnectionCloseSuccess(long duration,
java.util.concurrent.TimeUnit timeUnit)
onConnectionCloseSuccess in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onCustomEvent(java.lang.Object event)
onCustomEvent in interface io.reactivex.netty.events.EventListeneronCustomEvent in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onCustomEvent(java.lang.Object event,
long duration,
java.util.concurrent.TimeUnit timeUnit)
onCustomEvent in interface io.reactivex.netty.events.EventListeneronCustomEvent in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onCustomEvent(java.lang.Object event,
long duration,
java.util.concurrent.TimeUnit timeUnit,
java.lang.Throwable throwable)
onCustomEvent in interface io.reactivex.netty.events.EventListeneronCustomEvent in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic void onCustomEvent(java.lang.Object event,
java.lang.Throwable throwable)
onCustomEvent in interface io.reactivex.netty.events.EventListeneronCustomEvent in class io.reactivex.netty.channel.events.ConnectionEventListenerpublic boolean publishingEnabled()
publishingEnabled in interface io.reactivex.netty.events.EventPublisherpublic rx.Subscription subscribe(HttpClientEventsListener listener)
subscribe in interface io.reactivex.netty.events.EventSource<HttpClientEventsListener>public io.reactivex.netty.events.EventSource<io.reactivex.netty.protocol.tcp.client.events.TcpClientEventListener> asTcpEventSource()
public HttpClientEventPublisher copy()