Commit 34eb3632 by Spencer Gibb

Merge pull request #390 from heyjustin/master

Mark an instance as DOWN when the application context is stopped.
parents 12bee777 69eaa27c
...@@ -148,10 +148,10 @@ public class EurekaDiscoveryClientConfiguration implements SmartLifecycle, Order ...@@ -148,10 +148,10 @@ public class EurekaDiscoveryClientConfiguration implements SmartLifecycle, Order
@Override @Override
public void stop() { public void stop() {
log.info("Unregistering application " + this.instanceConfig.getAppname() log.info("Unregistering application " + this.instanceConfig.getAppname()
+ " with eureka with status OUT_OF_SERVICE"); + " with eureka with status DOWN");
if (ApplicationInfoManager.getInstance().getInfo() != null) { if (ApplicationInfoManager.getInstance().getInfo() != null) {
ApplicationInfoManager.getInstance().setInstanceStatus( ApplicationInfoManager.getInstance().setInstanceStatus(
InstanceStatus.OUT_OF_SERVICE); InstanceStatus.DOWN);
} }
this.running.set(false); this.running.set(false);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment