Package org.apache.solr.common.cloud
Class DefaultConnectionStrategy
java.lang.Object
org.apache.solr.common.cloud.ZkClientConnectionStrategy
org.apache.solr.common.cloud.DefaultConnectionStrategy
TODO: improve backoff retry impl
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.solr.common.cloud.ZkClientConnectionStrategy
ZkClientConnectionStrategy.ConnectedListener, ZkClientConnectionStrategy.DisconnectedListener, ZkClientConnectionStrategy.ZkUpdate -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidconnect(String serverAddress, int timeout, org.apache.zookeeper.Watcher watcher, ZkClientConnectionStrategy.ZkUpdate updater) voidreconnect(String serverAddress, int zkClientTimeout, org.apache.zookeeper.Watcher watcher, ZkClientConnectionStrategy.ZkUpdate updater) Methods inherited from class org.apache.solr.common.cloud.ZkClientConnectionStrategy
addConnectedListener, addDisconnectedListener, connected, createZooKeeper, disconnected, forName, getZkCredentialsToAddAutomatically, hasZkCredentialsToAddAutomatically, newZooKeeperInstance, removeDisconnectedListener, setZkCredentialsToAddAutomatically
-
Constructor Details
-
DefaultConnectionStrategy
public DefaultConnectionStrategy()
-
-
Method Details
-
connect
public void connect(String serverAddress, int timeout, org.apache.zookeeper.Watcher watcher, ZkClientConnectionStrategy.ZkUpdate updater) throws IOException, InterruptedException, TimeoutException - Specified by:
connectin classZkClientConnectionStrategy- Throws:
IOExceptionInterruptedExceptionTimeoutException
-
reconnect
public void reconnect(String serverAddress, int zkClientTimeout, org.apache.zookeeper.Watcher watcher, ZkClientConnectionStrategy.ZkUpdate updater) throws IOException, InterruptedException, TimeoutException - Specified by:
reconnectin classZkClientConnectionStrategy- Throws:
IOExceptionInterruptedExceptionTimeoutException
-