Package org.elasticsearch.transport
Class RemoteConnectionManager
java.lang.Object
org.elasticsearch.transport.RemoteConnectionManager
- All Implemented Interfaces:
Closeable
,AutoCloseable
,ConnectionManager
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.transport.ConnectionManager
ConnectionManager.ConnectionValidator, ConnectionManager.DelegatingNodeConnectionListener
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addListener
(TransportConnectionListener listener) void
close()
void
final void
connectToNode
(DiscoveryNode node, ConnectionProfile connectionProfile, ConnectionManager.ConnectionValidator connectionValidator, ActionListener<org.elasticsearch.core.Releasable> listener) Remote cluster connections have a different lifecycle from intra-cluster connections.void
connectToRemoteClusterNode
(DiscoveryNode node, ConnectionManager.ConnectionValidator connectionValidator, ActionListener<Void> listener) void
getConnection
(DiscoveryNode node) boolean
nodeConnected
(DiscoveryNode node) void
openConnection
(DiscoveryNode node, ConnectionProfile profile, ActionListener<Transport.Connection> listener) void
removeListener
(TransportConnectionListener listener) int
size()
-
Method Details
-
connectToNode
public final void connectToNode(DiscoveryNode node, ConnectionProfile connectionProfile, ConnectionManager.ConnectionValidator connectionValidator, ActionListener<org.elasticsearch.core.Releasable> listener) throws ConnectTransportException Remote cluster connections have a different lifecycle from intra-cluster connections. UseconnectToRemoteClusterNode(org.elasticsearch.cluster.node.DiscoveryNode, org.elasticsearch.transport.ConnectionManager.ConnectionValidator, org.elasticsearch.action.ActionListener<java.lang.Void>)
instead of this method.- Specified by:
connectToNode
in interfaceConnectionManager
- Throws:
ConnectTransportException
-
connectToRemoteClusterNode
public void connectToRemoteClusterNode(DiscoveryNode node, ConnectionManager.ConnectionValidator connectionValidator, ActionListener<Void> listener) throws ConnectTransportException - Throws:
ConnectTransportException
-
addListener
- Specified by:
addListener
in interfaceConnectionManager
-
removeListener
- Specified by:
removeListener
in interfaceConnectionManager
-
openConnection
public void openConnection(DiscoveryNode node, ConnectionProfile profile, ActionListener<Transport.Connection> listener) - Specified by:
openConnection
in interfaceConnectionManager
-
getConnection
- Specified by:
getConnection
in interfaceConnectionManager
-
nodeConnected
- Specified by:
nodeConnected
in interfaceConnectionManager
-
disconnectFromNode
- Specified by:
disconnectFromNode
in interfaceConnectionManager
-
getConnectionProfile
- Specified by:
getConnectionProfile
in interfaceConnectionManager
-
getAnyRemoteConnection
-
getAllConnectedNodes
- Specified by:
getAllConnectedNodes
in interfaceConnectionManager
-
size
public int size()- Specified by:
size
in interfaceConnectionManager
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfaceConnectionManager
-
closeNoBlock
public void closeNoBlock()- Specified by:
closeNoBlock
in interfaceConnectionManager
-