Sends the Quiet Down (Prepare for shutdown) message

@throws IOException in case of an error.
487144
public JenkinsServer quietDown() throws IOException {
        try {
            client.post("/quietDown/");
        } catch (org.apache.http.client.ClientProtocolException e) {
            LOGGER.error("quietDown()", e);
        }
        return this;
    }
759029
public void shutdown(ShutdownModeAmp mode,
                       ExitCode exitCode, 
                       String msg)
  {
    shutdown(mode, exitCode, msg, null);
  }
926917
void shutdown()
    {
        synchronized (this)
        {
            ivPoolCapacity = -1;
        }

        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
            Tr.debug(tc, "shutdown : " + this);

        EntityManager em = ivPool.poll();

        while (em != null)
        {
            if (em.isOpen())
            {
                em.close();
            }
            em = ivPool.poll();
        }

        synchronized (this)
        {
            ivPoolSize = 0;
        }
    }
471935
public void shutdown()
    {
        logger.info("Waiting for messaging service to quiesce");
        // We may need to schedule hints on the mutation stage, so it's erroneous to shut down the mutation stage first
        assert !StageManager.getStage(Stage.MUTATION).isShutdown();

        // the important part
        callbacks.shutdownBlocking();

        // attempt to humor tests that try to stop and restart MS
        try
        {
            for (SocketThread th : socketThreads)
                th.close();
        }
        catch (IOException e)
        {
            throw new IOError(e);
        }
    }
498261
private void stopOut() throws IOException {
    if (outClosed) {
      return;
    }
    outClosed = true;

    LOG.log(Level.FINE, "Shutting down socket for output");

    // close socket for output - that will initiate normal socket close procedure; in case of TCP
    // socket this is
    // a buffer flush and TCP termination
    socket.shutdownOutput();
  }
701473
private void notifyShutdown()
    {
        if (eventHandler instanceof LifecycleAware)
        {
            try
            {
                ((LifecycleAware) eventHandler).onShutdown();
            }
            catch (final Throwable ex)
            {
                exceptionHandler.handleOnShutdownException(ex);
            }
        }
    }
10708
@Override
    public synchronized void shutdown() {
        try {
            if (open) {
                open = false;
                writer.close();
            }
        } catch (IOException e) {
            logger.error("Error shutting down journal log", e);
        }
    }
950196
public void notifyShutdown() {
		// System.out.println(" AtomCache got notify shutdown..");
		if (pdpprovider != null) {
			if (pdpprovider instanceof RemotePDPProvider) {
				RemotePDPProvider remotePDP = (RemotePDPProvider) pdpprovider;
				remotePDP.flushCache();
			}
		}

		// todo: use a SCOP implementation that is backed by SerializableCache
		ScopDatabase scopInstallation = ScopFactory.getSCOP();
		if (scopInstallation != null) {
			if (scopInstallation instanceof CachedRemoteScopInstallation) {
				CachedRemoteScopInstallation cacheScop = (CachedRemoteScopInstallation) scopInstallation;
				cacheScop.flushCache();
			}
		}

	}
1336172
public void shutdown() throws IOException {
    // Clean up RPC connections.
    Iterator <ClientDatanodeProtocol> connections =
      datanodeMap.values().iterator();
    while(connections.hasNext()) {
      ClientDatanodeProtocol cnxn = connections.next();
      RPC.stopProxy(cnxn);
    }
    datanodeMap.clear();
    executor.shutdownNow();
    synchronized (leaseCheckers) {
      for (LeaseChecker checker : leaseCheckers.values()) {
        checker.closeRenewal();
      }
    }
  }
1154217
private void allowCleanShutdown() {
        DelayingShutdownHook hook = new DelayingShutdownHook();
        Context context = (Context) this.loggerFactory;
        hook.setContext(context);
        Thread hookThread = new Thread(hook, "Logback shutdown hook [" + context.getName() + "]");
        Runtime.getRuntime().addShutdownHook(hookThread);
    }
1352050
public void shutdown() {
    if (this.shuttingDown.getAndSet(true)) {
      // Already being shut down
      LOG.warn("DataNode.shutdown() was called while shutting down.");
      return;
    }
    if (infoServer != null) {
      try {
        infoServer.stop();
      } catch (Exception e) {
        LOG.warn("Exception shutting down DataNode", e);
      }
    }
    if (ipcServer != null) {
      ipcServer.stop();
    }
    this.shouldRun = false;
    if (dataXceiverServer != null) {
      ((DataXceiverServer) this.dataXceiverServer.getRunnable()).kill();
      this.dataXceiverServer.interrupt();

      // wait for all data receiver threads to exit
      if (this.threadGroup != null) {
        int retries = 0;
        while (true) {
          this.threadGroup.interrupt();
          LOG.info("Waiting for threadgroup to exit, active threads is " +
                   this.threadGroup.activeCount());
          if (this.threadGroup.activeCount() == 0) {
            break;
          }
          try {
            if (++retries > 600) {
              Thread[] activeThreads = new Thread[this.threadGroup.activeCount()];
              this.threadGroup.enumerate(activeThreads, true);
              LOG.info("Active Threads: " + Arrays.toString(activeThreads));
              LOG.warn("Waited for ThreadGroup to be empty for 10 minutes." + 
                        " SHUTTING DOWN NOW");
              break;
            }
            Thread.sleep(1000);
          } catch (InterruptedException e) {}
        }
      }
      // wait for dataXceiveServer to terminate
      try {
        this.dataXceiverServer.join();
      } catch (InterruptedException ie) {
      }
    }
    
    if (blockCopyExecutor != null && !blockCopyExecutor.isShutdown()) {
      blockCopyExecutor.shutdownNow();
    }
    
    if (namespaceManager != null) {
      namespaceManager.shutDownAll();
    }
    
    if (blockScanner != null) { 
      blockScanner.shutdown();
    }
    if(directoryScanner != null) {
      shutdownDirectoryScanner();
    }
    if (storage != null) {
      try {
        this.storage.unlockAll();
      } catch (IOException ie) {
      }
    }
    if (data != null) {
      data.shutdown();
    }
    if (myMetrics != null) {
      setCountingLoggers(null);
      myMetrics.shutdown();
    }
    this.shutdownMXBean();
  }
1058970
final void shutdown() {
        _enabled = false;
        _ignoredSegs.clear();
        
        if(_executor != null && !_executor.isShutdown()) {
            try {
                _executor.shutdown();
                _log.info("shutdown");
            } catch (Exception e) {
                _log.warn("shutdown abort", e);
            }
            
            try {
                _executor.awaitTermination(_shutdownTimeout, TimeUnit.SECONDS);
            } catch (Exception e) {
                _log.warn("shutdown abort", e);
            }
            
            if(_segTarget != null) {
                try {
                    _updateManager.endUpdate(_segTarget);
                } catch (Exception e) {
                    _log.warn("shutdown abort", e);
                }
            }
        }
        
        _executor = null;
        _state = State.DONE;
    }
254642
def shutdown(exception)
      begin
        notify_event(:shutdown, { :exception_message => exception.message })
      rescue => e
        $stderr.puts([e.message, e.backtrace].join("\n")) rescue nil
      end
      @config = default_config
      @config[:enabled] = false
    end
686650
public function onShutdown()
    {
        // Get the last error if there was one, if not, let's get out of here.
        if (!$error = error_get_last()) {
            return;
        }

        $fatal  = array(E_ERROR,E_PARSE,E_CORE_ERROR,E_COMPILE_ERROR,E_USER_ERROR,E_RECOVERABLE_ERROR);
        if (!in_array($error['type'], $fatal)) {
            return;
        }

        $message   = '[Shutdown Error]: %s';
        $message   = sprintf($message, $error['message']);
        $backtrace = array(array('file' => $error['file'], 'line' => $error['line']));

        $this->client->notifyOnError($message, $backtrace, 'error');
        error_log($message.' in: '.$error['file'].':'.$error['line']);
    }
278705
public void setShutdown(java.util.Collection<String> shutdown) {
        if (shutdown == null) {
            this.shutdown = null;
            return;
        }

        this.shutdown = new com.amazonaws.internal.SdkInternalList<String>(shutdown);
    }
445377
public void shutdown() {
	    if (shutdown) 
	    {
	        return;
	    }
	    shutdown = true;
	    synchronized (workers) 
	    {
	        for (int i = workers.size(); i > 0; i--) 
	        {
	        	systemExecute(exitTask);
	        }
	        waitConditionStrategy.signalAllWhenBlocking();
	    }
	}
514623
public void shutdown()
	{
		try {
			thread.signalShutdown();
			thread.join();
			thread = null;
		} catch (InterruptedException e) {
			LOGGER.warn("Interrupted while waiting for queue shutdown, may not have completed cleanly", e);
		}
	}