Browse Source

AMBARI-24845. Sometimes host status still in heartbeat lost after agent become heartbeating. (mpapirkovskyy) (#2562)

Myroslav Papirkovskyi 7 years ago
parent
commit
4945cd0acf

+ 2 - 0
ambari-server/src/main/java/org/apache/ambari/server/state/host/HostImpl.java

@@ -360,6 +360,8 @@ public class HostImpl implements Host {
 
       host.topologyManager.onHostRegistered(host, associatedWithCluster);
 
+      host.setHealthStatus(new HostHealthStatus(HealthStatus.HEALTHY,
+          host.getHealthStatus().getHealthReport()));
       // initialize agent times in the last time to prevent setting registering/heartbeat times for failed registration.
       host.updateHostTimestamps(e);
     }