public abstract class ExtendedAsyncHandler<T> extends Object implements AsyncHandler<T>, AsyncHandlerExtensions
AsyncHandler.State
Constructor and Description |
---|
ExtendedAsyncHandler() |
Modifier and Type | Method and Description |
---|---|
void |
onConnectionOffer(io.netty.channel.Channel connection)
Notify the callback when trying to offer a connection to the pool.
|
void |
onConnectionPool()
Notify the callback when trying to fetch a connection from the pool.
|
void |
onConnectionPooled(io.netty.channel.Channel connection)
Notify the callback when a new connection was successfully fetched from the pool.
|
void |
onHostnameResolutionAttempt(String name)
Notify the callback before hostname resolution
|
void |
onHostnameResolutionFailure(String name,
Throwable cause)
Notify the callback after hostname resolution failed.
|
void |
onHostnameResolutionSuccess(String name,
List<InetSocketAddress> addresses)
Notify the callback after hostname resolution was successful.
|
void |
onRequestSend(NettyRequest request)
Notify the callback when a request is being written on the channel.
|
void |
onRetry()
Notify the callback every time a request is being retried.
|
void |
onTcpConnect(InetSocketAddress address)
Notify the callback when trying to open a new connection.
|
void |
onTcpConnectFailure(InetSocketAddress remoteAddress,
Throwable cause)
Notify the callback after a failed connect.
|
void |
onTcpConnectSuccess(InetSocketAddress remoteAddress,
io.netty.channel.Channel connection)
Notify the callback after a successful connect
|
void |
onTlsHandshake()
Notify the callback before TLS handshake
|
void |
onTlsHandshakeFailure(Throwable cause)
Notify the callback after the TLS failed
|
void |
onTlsHandshakeSuccess()
Notify the callback after the TLS was successful
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
onBodyPartReceived, onCompleted, onHeadersReceived, onStatusReceived, onThrowable
public void onHostnameResolutionAttempt(String name)
AsyncHandlerExtensions
onHostnameResolutionAttempt
in interface AsyncHandlerExtensions
name
- the name to be resolvedpublic void onHostnameResolutionSuccess(String name, List<InetSocketAddress> addresses)
AsyncHandlerExtensions
onHostnameResolutionSuccess
in interface AsyncHandlerExtensions
name
- the name to be resolvedaddresses
- the resolved addressespublic void onHostnameResolutionFailure(String name, Throwable cause)
AsyncHandlerExtensions
onHostnameResolutionFailure
in interface AsyncHandlerExtensions
name
- the name to be resolvedcause
- the failure causepublic void onTcpConnect(InetSocketAddress address)
AsyncHandlerExtensions
onTcpConnect
in interface AsyncHandlerExtensions
address
- the address we try to connect topublic void onTcpConnectSuccess(InetSocketAddress remoteAddress, io.netty.channel.Channel connection)
AsyncHandlerExtensions
onTcpConnectSuccess
in interface AsyncHandlerExtensions
remoteAddress
- the address we try to connect toconnection
- the connectionpublic void onTcpConnectFailure(InetSocketAddress remoteAddress, Throwable cause)
AsyncHandlerExtensions
onTcpConnectFailure
in interface AsyncHandlerExtensions
remoteAddress
- the address we try to connect tocause
- the cause of the failurepublic void onTlsHandshake()
AsyncHandlerExtensions
onTlsHandshake
in interface AsyncHandlerExtensions
public void onTlsHandshakeSuccess()
AsyncHandlerExtensions
onTlsHandshakeSuccess
in interface AsyncHandlerExtensions
public void onTlsHandshakeFailure(Throwable cause)
AsyncHandlerExtensions
onTlsHandshakeFailure
in interface AsyncHandlerExtensions
cause
- the cause of the failurepublic void onConnectionPool()
AsyncHandlerExtensions
onConnectionPool
in interface AsyncHandlerExtensions
public void onConnectionPooled(io.netty.channel.Channel connection)
AsyncHandlerExtensions
onConnectionPooled
in interface AsyncHandlerExtensions
connection
- the connectionpublic void onConnectionOffer(io.netty.channel.Channel connection)
AsyncHandlerExtensions
onConnectionOffer
in interface AsyncHandlerExtensions
connection
- the connectionpublic void onRequestSend(NettyRequest request)
AsyncHandlerExtensions
onRequestSend
in interface AsyncHandlerExtensions
request
- the real request object as passed to the providerpublic void onRetry()
AsyncHandlerExtensions
onRetry
in interface AsyncHandlerExtensions
Copyright © 2015. All Rights Reserved.