Package org.flasby.net.heartbeat
Interface ServiceInfo
public interface ServiceInfo
models the heartbeat state and identity of a service.
- Author:
- steve
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptiongetId()
identifies the service.long
returns the time when the last heartbeat was sent by this service.long
-
Method Details
-
getId
String getId()identifies the service. This must be unique for all cooperating services within this service cluster.- Returns:
-
getLastHeartbeatSentTime
long getLastHeartbeatSentTime()returns the time when the last heartbeat was sent by this service. The time is set by the sending service and is not synchronized with any other service.- Returns:
-
getLastHeartReceivedTime
long getLastHeartReceivedTime()- Returns:
-
getStatus
ServiceInfo.Status getStatus()
-