public void stop ( int rc ) { this . resultCode = rc ; LOG . info ( "Stopping Journal Node: " + this ) ; if ( rpcServer != null ) { rpcServer . stop ( ) ; rpcServer = null ; } if ( httpServer != null ) { try { httpServer . stop ( ) ; } catch ( IOException ioe ) { LOG . warn ( "Unable to stop HTTP server for " + this , ioe ) ; } } for ( Journal j : journalsById . values ( ) ) { IOUtils . cleanup ( LOG , j ) ; } if ( metrics != null ) { metrics . shutdown ( ) ; } if ( journalSyncer != null ) { journalSyncer . stop ( ) ; } }
Stop the daemon with the given status code