Package com.netflix.eureka.registry.rule
Interface InstanceStatusOverrideRule
-
- All Known Implementing Classes:
AlwaysMatchInstanceStatusRule,AsgEnabledRule,DownOrStartingRule,FirstMatchWinsCompositeRule,LeaseExistsRule,OverrideExistsRule
public interface InstanceStatusOverrideRuleA single rule that if matched it returns an instance status. The idea is to use an ordered list of such rules and pick the first result that matches. It is designed to be used byAbstractInstanceRegistry.getOverriddenInstanceStatus(InstanceInfo, Lease, boolean)Created by Nikos Michalakis on 7/13/16.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StatusOverrideResultapply(com.netflix.appinfo.InstanceInfo instanceInfo, Lease<com.netflix.appinfo.InstanceInfo> existingLease, boolean isReplication)Match this rule.
-
-
-
Method Detail
-
apply
StatusOverrideResult apply(com.netflix.appinfo.InstanceInfo instanceInfo, Lease<com.netflix.appinfo.InstanceInfo> existingLease, boolean isReplication)
Match this rule.- Parameters:
instanceInfo- The instance info whose status we care about.existingLease- Does the instance have an existing lease already? If so let's consider that.isReplication- When overriding consider if we are under a replication mode from other servers.- Returns:
- A result with whether we matched and what we propose the status to be overriden to.
-
-