Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2223,7 +2223,6 @@ public boolean stop() {
}
if (omRatisServer != null) {
omRatisServer.stop();
omRatisServer = null;
OMHAMetrics.unRegister();
}
isOmRpcServerRunning = false;
Expand Down Expand Up @@ -2260,6 +2259,7 @@ public boolean stop() {
if (omhaMetrics != null) {
OMHAMetrics.unRegister();
}
omRatisServer = null;
return true;
} catch (Exception e) {
LOG.error("OzoneManager stop failed.", e);
Expand Down Expand Up @@ -3032,6 +3032,9 @@ public String getRatisRoles() {
int port = omNodeDetails.getRatisPort();
RaftPeer leaderId;
if (isRatisEnabled) {
if (null == omRatisServer) {
return "Server is shutting down";
}
try {
leaderId = omRatisServer.getLeader();
if (leaderId == null) {
Expand Down