HDFS-14923. Remove dead code from HealthMonitor. Contributed by Fei Hui.

Signed-off-by: Wei-Chiu Chuang <weichiu@apache.org>
This commit is contained in:
Fei Hui 2019-10-25 15:05:31 -07:00 committed by Wei-Chiu Chuang
parent 30db895b59
commit 7be5508d9b

View File

@ -137,19 +137,11 @@ public enum State {
public void addCallback(Callback cb) {
this.callbacks.add(cb);
}
public void removeCallback(Callback cb) {
callbacks.remove(cb);
}
public synchronized void addServiceStateCallback(ServiceStateCallback cb) {
this.serviceStateCallbacks.add(cb);
}
public synchronized void removeServiceStateCallback(ServiceStateCallback cb) {
serviceStateCallbacks.remove(cb);
}
public void shutdown() {
LOG.info("Stopping HealthMonitor thread");
shouldRun = false;
@ -261,11 +253,7 @@ private synchronized void enterState(State newState) {
synchronized State getHealthState() {
return state;
}
synchronized HAServiceStatus getLastServiceStatus() {
return lastServiceState;
}
boolean isAlive() {
return daemon.isAlive();
}