code: 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();
      }
    }
docs: Stop the daemon with the given status code
  @param rc the status code with which to exit (non-zero
  should indicate an error)