I - Type of the incoming payloadO - Type of the outgoing payloadpublic interface HeartbeatListener<I,O>
HeartbeatManager. The heartbeat listener is used
for the following things:
| Modifier and Type | Method and Description |
|---|---|
void |
notifyHeartbeatTimeout(ResourceID resourceID)
Callback which is called if a heartbeat for the machine identified by the given resource ID
times out.
|
void |
notifyTargetUnreachable(ResourceID resourceID)
Callback which is called if a target specified by the given resource ID is no longer
reachable.
|
void |
reportPayload(ResourceID resourceID,
I payload)
Callback which is called whenever a heartbeat with an associated payload is received.
|
O |
retrievePayload(ResourceID resourceID)
Retrieves the payload value for the next heartbeat message.
|
void notifyHeartbeatTimeout(ResourceID resourceID)
resourceID - Resource ID of the machine whose heartbeat has timed outvoid notifyTargetUnreachable(ResourceID resourceID)
resourceID - resourceID identifying the target that is no longer reachablevoid reportPayload(ResourceID resourceID, I payload)
resourceID - Resource ID identifying the sender of the payloadpayload - Payload of the received heartbeatO retrievePayload(ResourceID resourceID)
resourceID - Resource ID identifying the receiver of the payloadCopyright © 2014–2022 The Apache Software Foundation. All rights reserved.