HDFS-12129. Ozone: SCM http server is not stopped with SCM#stop(). Contributed by Weiwei Yang.

This commit is contained in:
Weiwei Yang 2017-07-13 16:10:58 +08:00 committed by Owen O'Malley
parent ea5e24c925
commit a4cbd33dd5
1 changed files with 9 additions and 1 deletions

View File

@ -509,8 +509,16 @@ public class StorageContainerManager
LOG.info("Stopping the RPC server for DataNodes");
datanodeRpcServer.stop();
} catch (Exception ex) {
LOG.error("Storage Container Manager httpServer stop failed.", ex);
LOG.error("Storage Container Manager datanodeRpcServer stop failed.", ex);
}
try {
LOG.info("Stopping Storage Container Manager HTTP server.");
httpServer.stop();
} catch (Exception ex) {
LOG.error("Storage Container Manager HTTP server stop failed.", ex);
}
unregisterMXBean();
IOUtils.closeQuietly(scmContainerManager);
IOUtils.closeQuietly(scmBlockManager);