Package org.apache.drill.exec.rpc
Class ReconnectingConnection<C extends ClientConnection,HS extends com.google.protobuf.MessageLite>
java.lang.Object
org.apache.drill.exec.rpc.ReconnectingConnection<C,HS>
- All Implemented Interfaces:
Closeable,AutoCloseable
- Direct Known Subclasses:
ControlConnectionManager,DataConnectionManager
public abstract class ReconnectingConnection<C extends ClientConnection,HS extends com.google.protobuf.MessageLite>
extends Object
implements Closeable
Manager all connections between two particular bits.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected classListens for connection closes and clears connection holder.classFactory for close handlersclassReconnectingConnection.ConnectionListeningFuture<R extends com.google.protobuf.MessageLite,E extends com.google.protobuf.Internal.EnumLite, M extends com.google.protobuf.MessageLite> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddExternalConnection(C connection) voidclose()protected abstract BasicClient<?, C, HS, ?> <T extends com.google.protobuf.MessageLite,E extends com.google.protobuf.Internal.EnumLite, M extends com.google.protobuf.MessageLite, R extends RpcCommand<T, C, E, M>>
voidrunCommand(R cmd)
-
Constructor Details
-
ReconnectingConnection
-
-
Method Details
-
getNewClient
-
runCommand
public <T extends com.google.protobuf.MessageLite,E extends com.google.protobuf.Internal.EnumLite, void runCommandM extends com.google.protobuf.MessageLite, R extends RpcCommand<T, C, E, M>> (R cmd) -
getCloseHandlerCreator
-
addExternalConnection
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-