org.elkoserver.foundation.net
Class ConnectionRetrier
java.lang.Object
org.elkoserver.foundation.net.ConnectionRetrier
public class ConnectionRetrier
- extends Object
Worker object to manage an ongoing attempt to establish an outbound TCP
connection, so that failed connection attempts can be retried automatically.
|
Method Summary |
void |
giveUp()
Stop retrying this connection. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ConnectionRetrier
public ConnectionRetrier(HostDesc host,
String label,
NetworkManager networkManager,
MessageHandlerFactory actualFactory,
Trace appTrace)
- Attempt to initiate a connection to another host, with retry on failure.
- Parameters:
host - Description of host to connect to.label - String describing remote connection endpoint, for
diagnostic outputnetworkManager - Network manager to actually make the connection.actualFactory - Application-provided message handler factory for
use once connection is established.appTrace - Application trace object for logging.
giveUp
public void giveUp()
- Stop retrying this connection.