[motify info] config health info
This commit is contained in:
parent
89c5c8fd76
commit
8c7dcd7bb3
@ -100,4 +100,11 @@ public interface ConfigService {
|
||||
*/
|
||||
public void removeListener(String dataId, String group, Listener listener);
|
||||
|
||||
/**
|
||||
* server health info
|
||||
*
|
||||
* @return whether health
|
||||
*/
|
||||
public String getServerStatus();
|
||||
|
||||
}
|
||||
|
@ -264,4 +264,13 @@ public class NacosConfigService implements ConfigService {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getServerStatus() {
|
||||
if (worker.isHealthServer()) {
|
||||
return "UP";
|
||||
} else {
|
||||
return "DOWN";
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user