Class DefaultAsyncClientConnectionOperator
- java.lang.Object
-
- org.apache.hc.client5.http.impl.nio.DefaultAsyncClientConnectionOperator
-
- All Implemented Interfaces:
AsyncClientConnectionOperator
final class DefaultAsyncClientConnectionOperator extends java.lang.Object implements AsyncClientConnectionOperator
-
-
Field Summary
Fields Modifier and Type Field Description private SchemePortResolver
schemePortResolver
private MultihomeIOSessionRequester
sessionRequester
private org.apache.hc.core5.http.config.Lookup<org.apache.hc.core5.http.nio.ssl.TlsStrategy>
tlsStrategyLookup
-
Constructor Summary
Constructors Constructor Description DefaultAsyncClientConnectionOperator(org.apache.hc.core5.http.config.Lookup<org.apache.hc.core5.http.nio.ssl.TlsStrategy> tlsStrategyLookup, SchemePortResolver schemePortResolver, DnsResolver dnsResolver)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.concurrent.Future<ManagedAsyncClientConnection>
connect(org.apache.hc.core5.reactor.ConnectionInitiator connectionInitiator, org.apache.hc.core5.http.HttpHost host, java.net.SocketAddress localAddress, org.apache.hc.core5.util.Timeout connectTimeout, java.lang.Object attachment, org.apache.hc.core5.concurrent.FutureCallback<ManagedAsyncClientConnection> callback)
Initiates operation to create a connection to the remote endpoint using the providedConnectionInitiator
.java.util.concurrent.Future<ManagedAsyncClientConnection>
connect(org.apache.hc.core5.reactor.ConnectionInitiator connectionInitiator, org.apache.hc.core5.http.HttpHost host, java.net.SocketAddress localAddress, org.apache.hc.core5.util.Timeout connectTimeout, java.lang.Object attachment, org.apache.hc.core5.http.protocol.HttpContext context, org.apache.hc.core5.concurrent.FutureCallback<ManagedAsyncClientConnection> callback)
Initiates operation to create a connection to the remote endpoint using the providedConnectionInitiator
.void
upgrade(ManagedAsyncClientConnection connection, org.apache.hc.core5.http.HttpHost host, java.lang.Object attachment)
Upgrades transport security of the given managed connection by using the TLS security protocol.void
upgrade(ManagedAsyncClientConnection connection, org.apache.hc.core5.http.HttpHost host, java.lang.Object attachment, org.apache.hc.core5.http.protocol.HttpContext context)
Upgrades transport security of the given managed connection by using the TLS security protocol.void
upgrade(ManagedAsyncClientConnection connection, org.apache.hc.core5.http.HttpHost host, java.lang.Object attachment, org.apache.hc.core5.http.protocol.HttpContext context, org.apache.hc.core5.concurrent.FutureCallback<ManagedAsyncClientConnection> callback)
Upgrades transport security of the given managed connection by using the TLS security protocol.
-
-
-
Field Detail
-
schemePortResolver
private final SchemePortResolver schemePortResolver
-
sessionRequester
private final MultihomeIOSessionRequester sessionRequester
-
tlsStrategyLookup
private final org.apache.hc.core5.http.config.Lookup<org.apache.hc.core5.http.nio.ssl.TlsStrategy> tlsStrategyLookup
-
-
Constructor Detail
-
DefaultAsyncClientConnectionOperator
DefaultAsyncClientConnectionOperator(org.apache.hc.core5.http.config.Lookup<org.apache.hc.core5.http.nio.ssl.TlsStrategy> tlsStrategyLookup, SchemePortResolver schemePortResolver, DnsResolver dnsResolver)
-
-
Method Detail
-
connect
public java.util.concurrent.Future<ManagedAsyncClientConnection> connect(org.apache.hc.core5.reactor.ConnectionInitiator connectionInitiator, org.apache.hc.core5.http.HttpHost host, java.net.SocketAddress localAddress, org.apache.hc.core5.util.Timeout connectTimeout, java.lang.Object attachment, org.apache.hc.core5.concurrent.FutureCallback<ManagedAsyncClientConnection> callback)
Description copied from interface:AsyncClientConnectionOperator
Initiates operation to create a connection to the remote endpoint using the providedConnectionInitiator
.- Specified by:
connect
in interfaceAsyncClientConnectionOperator
- Parameters:
connectionInitiator
- the connection initiator.host
- the address of the opposite endpoint.localAddress
- the address of the local endpoint.connectTimeout
- the timeout of the connect operation.attachment
- the attachment, which can be any object representing custom parameter of the operation.callback
- the future result callback.
-
connect
public java.util.concurrent.Future<ManagedAsyncClientConnection> connect(org.apache.hc.core5.reactor.ConnectionInitiator connectionInitiator, org.apache.hc.core5.http.HttpHost host, java.net.SocketAddress localAddress, org.apache.hc.core5.util.Timeout connectTimeout, java.lang.Object attachment, org.apache.hc.core5.http.protocol.HttpContext context, org.apache.hc.core5.concurrent.FutureCallback<ManagedAsyncClientConnection> callback)
Description copied from interface:AsyncClientConnectionOperator
Initiates operation to create a connection to the remote endpoint using the providedConnectionInitiator
.- Specified by:
connect
in interfaceAsyncClientConnectionOperator
- Parameters:
connectionInitiator
- the connection initiator.host
- the address of the opposite endpoint.localAddress
- the address of the local endpoint.connectTimeout
- the timeout of the connect operation.attachment
- the attachment, which can be any object representing custom parameter of the operation.context
- the execution context.callback
- the future result callback.
-
upgrade
public void upgrade(ManagedAsyncClientConnection connection, org.apache.hc.core5.http.HttpHost host, java.lang.Object attachment)
Description copied from interface:AsyncClientConnectionOperator
Upgrades transport security of the given managed connection by using the TLS security protocol.- Specified by:
upgrade
in interfaceAsyncClientConnectionOperator
- Parameters:
connection
- the managed connection.host
- the address of the opposite endpoint with TLS security.attachment
- the attachment, which can be any object representing custom parameter of the operation.
-
upgrade
public void upgrade(ManagedAsyncClientConnection connection, org.apache.hc.core5.http.HttpHost host, java.lang.Object attachment, org.apache.hc.core5.http.protocol.HttpContext context)
Description copied from interface:AsyncClientConnectionOperator
Upgrades transport security of the given managed connection by using the TLS security protocol.- Specified by:
upgrade
in interfaceAsyncClientConnectionOperator
- Parameters:
connection
- the managed connection.host
- the address of the opposite endpoint with TLS security.attachment
- the attachment, which can be any object representing custom parameter of the operation.context
- the execution context.
-
upgrade
public void upgrade(ManagedAsyncClientConnection connection, org.apache.hc.core5.http.HttpHost host, java.lang.Object attachment, org.apache.hc.core5.http.protocol.HttpContext context, org.apache.hc.core5.concurrent.FutureCallback<ManagedAsyncClientConnection> callback)
Description copied from interface:AsyncClientConnectionOperator
Upgrades transport security of the given managed connection by using the TLS security protocol.- Specified by:
upgrade
in interfaceAsyncClientConnectionOperator
- Parameters:
connection
- the managed connection.host
- the address of the opposite endpoint with TLS security.attachment
- the attachment, which can be any object representing custom parameter of the operation.context
- the execution context.callback
- the future result callback.
-
-