public class GlobalHostStatusTracker
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
(package private) static class |
GlobalHostStatusTracker.HostSpecStatus |
| Modifier and Type | Field and Description |
|---|---|
private static java.util.Map<HostSpec,GlobalHostStatusTracker.HostSpecStatus> |
hostStatusMap |
| Constructor and Description |
|---|
GlobalHostStatusTracker() |
| Modifier and Type | Method and Description |
|---|---|
(package private) static java.util.List<HostSpec> |
getCandidateHosts(HostSpec[] hostSpecs,
HostRequirement targetServerType,
long hostRecheckMillis)
Returns a list of candidate hosts that have the required targetServerType.
|
static void |
reportHostStatus(HostSpec hostSpec,
HostStatus hostStatus)
Store the actual observed host status.
|
private static final java.util.Map<HostSpec,GlobalHostStatusTracker.HostSpecStatus> hostStatusMap
public static void reportHostStatus(HostSpec hostSpec, HostStatus hostStatus)
hostSpec - The host whose status is known.hostStatus - Latest known status for the host.static java.util.List<HostSpec> getCandidateHosts(HostSpec[] hostSpecs, HostRequirement targetServerType, long hostRecheckMillis)
hostSpecs - The potential list of hosts.targetServerType - The required target server type.hostRecheckMillis - How stale information is allowed.