次のコマンドを実行します。

<pre>
mvn jetty:stop
</pre>
515481
public void stop(Path baseDir, Path sampleDir, ProcessExitCallback callback) {
        if (!sampleDir.toFile().exists() && callback != null) {
            callback.callback(0);
        }

        ProcessCommand cmd = MavenProject.load(baseDir).mvnw("jetty:stop", "-f",
                sampleDir.toString());
        if (callback != null)
            cmd.getExitCallbacks().add(callback);
        cmd.executeAsync();
    }
71945
@Override
    public void shutdown() {
        final WireMockServer server = this;
        Thread shutdownThread = new Thread(new Runnable() {
            @Override
            public void run() {
                try {
                    // We have to sleep briefly to finish serving the shutdown request before stopping the server, as
                    // there's no support in Jetty for shutting down after the current request.
                    // See http://stackoverflow.com/questions/4650713
                    Thread.sleep(100);
                } catch (InterruptedException e) {
                    throw new RuntimeException(e);
                }
                server.stop();
            }
        });
        shutdownThread.start();
    }
240306
public boolean stop()
    throws Exception
  {
    /*
    if (_clusterServerPublisher != null) {
      _clusterServerPublisher.onServerStop(_selfServer.getServerBartender());
    }
    */
    
    try {
      if (_portPublic != null) {
        _portPublic.close();
      }
    } catch (Throwable e) {
      log.log(Level.WARNING, e.toString(), e);
    }
    
    try {
      if (_portBartender != null) {
        _portBartender.close();
      }
    } catch (Throwable e) {
      log.log(Level.WARNING, e.toString(), e);
    }
    
    return true;
  }
1207548
public static void main(String[] args) {
        CitrusRemoteServer server = new CitrusRemoteServer(args);

        if (server.configuration.getTimeToLive() > 0) {
            CompletableFuture.runAsync(() -> {
                try {
                    new CompletableFuture<Void>().get(server.configuration.getTimeToLive(), TimeUnit.MILLISECONDS);
                } catch (InterruptedException | ExecutionException | TimeoutException e) {
                    server.stop();
                }
            });
        }

        server.start();

        if (server.configuration.isSystemExit()) {
            if (server.waitForCompletion()) {
                System.exit(0);
            } else {
                System.exit(-1);
            }
        } else {
            server.waitForCompletion();
        }
    }
307338
def stop(ctx, service, editable):
    """"""
    logger.debug("running command %s (%s)", ctx.command.name, ctx.params,
                 extra={"command": ctx.command.name, "params": ctx.params})

    home = ctx.obj["HOME"]
    service_path = plugin_utils.get_plugin_path(home, SERVICES, service, editable)

    logger.debug("loading {}".format(service))
    service = register_service(service_path)

    try:
        with open(os.path.join(service_path, ARGS_JSON)) as f:
            service_args = json.loads(f.read())
    except IOError as exc:
        logger.debug(str(exc), exc_info=True)
        raise click.ClickException("Cannot load service args, are you sure server is running?")

    # get our service class instance
    service_module = get_service_module(service_path)
    service_obj = service_module.service_class(alert_types=service.alert_types, service_args=service_args)

    # prepare runner
    runner = myRunner(service_obj,
                      pidfile=service_path + ".pid",
                      stdout=open(os.path.join(service_path, "stdout.log"), "ab"),
                      stderr=open(os.path.join(service_path, "stderr.log"), "ab"))

    click.secho("[*] Stopping {}".format(service.name))
    try:
        runner._stop()
    except daemon.runner.DaemonRunnerStopFailureError as exc:
        logger.debug(str(exc), exc_info=True)
        raise click.ClickException("Unable to stop service, are you sure it is running?")
297798
public void postDeregister()
    {
        _configuration=null;   
        try
        {
            if (null!=_jettyServer)
                _jettyServer.stop();
        }
        catch(Exception e)
        {
            log.warn(e);
        }
        finally
        {
            super.postDeregister();
        }
        
    }
1059680
def exit(self):
        """"""
        for t in itervalues(self.thread_list):
            t.stop()
        # Call the father class
        super(Plugin, self).exit()
1340067
def stop():
    
    global global_server
    if global_server is not None:
        ioloop = global_server.ioloop
        def stop_ioloop():
            ioloop.stop()
            ioloop.close()
        global_server.ioloop.add_callback(stop_ioloop)
        global_server = None
1119707
public void stop() {
    if (stopRequested) {
      return;
    }
    stopRequested = true;
    running = false;
    if (server != null) server.stop();
    if (triggerThread != null) triggerThread.interrupt();
    if (fileFixer != null) fileFixer.shutdown();
    if (fileFixerThread != null) fileFixerThread.interrupt();
    if (myMetrics != null) {
      myMetrics.shutdown();
    }
  }
933919
public static void main(final String[] args)
			throws Exception {
		// Use jetty to run the servlet.
		Server server = new Server();

		SocketConnector connector = new SocketConnector();
		connector.setMaxIdleTime(0);
		connector.setPort(8080);
		server.addConnector(connector);

		WebAppContext context = new WebAppContext();
		context.setContextPath("/");
		context.addServlet(HelloWServlet.class.getName(), "/*");
		context.addServlet(ThemeServlet.class.getName(), "/theme/*");
		context.setResourceBase(".");

		server.setHandler(context);
		server.start();
	}
961388
private int stop(final String[] args) throws IOException {
    setWorkingDir(args);
    final Path statusFile = getStatusPath();
    int exitStatus = 1;

    // determine the current state of the node
    readStatus(false, statusFile);
    if (this.status != null) {
      // upon reading the status file, request the Cache Server to shutdown
      // if it has not already...
      if (this.status.state != Status.SHUTDOWN) {
        // copy server PID and not use own PID; see bug #39707
        this.status = Status.create(this.baseName, Status.SHUTDOWN_PENDING,
            this.status.pid, statusFile);
        this.status.write();
      }

      // poll the Cache Server for a response to our shutdown request
      // (passes through if the Cache Server has already shutdown)
      pollCacheServerForShutdown(statusFile);

      // after polling, determine the status of the Cache Server one last time
      // and determine how to exit...
      if (this.status.state == Status.SHUTDOWN) {
        System.out.println(MessageFormat.format(LAUNCHER_STOPPED,
            this.baseName, getHostNameAndDir()));
        Status.delete(statusFile);
        exitStatus = 0;
      } else {
        System.out.println(MessageFormat.format(LAUNCHER_TIMEOUT_WAITING_FOR_SHUTDOWN,
            this.baseName, this.hostName, this.status));
      }
    } else if (Files.exists(statusFile)) {
      throw new IllegalStateException(MessageFormat.format(
          LAUNCHER_NO_AVAILABLE_STATUS, this.statusName));
    } else {
      System.out.println(MessageFormat.format(LAUNCHER_NO_STATUS_FILE,
          this.workingDir, this.hostName));
    }
    return exitStatus;
  }
1207789
public void stop() throws Exception {
        DruidIndices.getInstance().remove(String.valueOf(port));
        server.stop();
    }
1269231
public void stop() {
        if (!Utils.isNullOrEmpty(context.getSettings().getExportFile())) {
            if (Utils.isNullOrEmpty(context.getSettings().getExportFilter())) {
                JAXB.marshal(export, new File(context.getSettings().getExportFile()));
            } else {
                Symbols exportFiltered = new Symbols();
                Pattern regexp = Pattern.compile(context.getSettings().getExportFilter());
                for (String symbol : export.getSymbols()) {
                    if (regexp.matcher(symbol).matches()) {
                        exportFiltered.getSymbols().add(symbol);
                    }
                }
                JAXB.marshal(exportFiltered, new File(context.getSettings().getExportFile()));
            }
        }
        if (context.getSettings().isClean()) {
            for (File file : oldFiles) {
                logInfo("deleting " + file.getName());
                if (!file.delete()) {
                    logInfo("failed");
                }
                ++deleted;
            }
        }
        try {
            final BufferedOutputStream out = new BufferedOutputStream(new FileOutputStream(java4cppHash));
            newHashes.store(out, "Generated by java4cpp");
            out.close();
        } catch (IOException e) {
            throw new RuntimeException("Failed to generate java4cpp.hash " + e.getMessage());
        }
        logInfo(String.format("generated: %d, imported: %d, skipped: %d, deleted: %d", generated, imported, skipped, deleted));
    }
30263
@PreDestroy
    public void stop() throws Exception {
        JmxUtils2.unregisterObject(queryMbeanObjectName, embeddedJmxTrans.getMbeanServer());

        for (OutputWriter outputWriter : outputWriters) {
            outputWriter.stop();
        }
    }
1142841
def stop(self):
        
        if self.server.eio.async_mode == 'threading':
            func = flask.request.environ.get('werkzeug.server.shutdown')
            if func:
                func()
            else:
                raise RuntimeError('Cannot stop unknown web server')
        elif self.server.eio.async_mode == 'eventlet':
            raise SystemExit
        elif self.server.eio.async_mode == 'gevent':
            self.wsgi_server.stop()
1280359
public static void main(String[] args) {
		// manager with two stopwatches is created
		Manager manager = new EnabledManager();
		Stopwatch sw1 = manager.getStopwatch("org.javasimon.examples.stopwatch1");
		Stopwatch sw2 = manager.getStopwatch("other.stopwatch2");

		// simple callback printing actions to the stdout is created and installed
		Callback stdoutCallback = new CallbackSkeleton() {
			@Override
			public void onStopwatchStart(Split split) {
				System.out.println("Starting " + split.getStopwatch().getName());
			}

			@Override
			public void onStopwatchStop(Split split, StopwatchSample sample) {
				System.out.println("Stopped " + split.getStopwatch().getName() + " (" + SimonUtils.presentNanoTime(split.runningFor()) + ")");
			}
		};
		manager.callback().addCallback(stdoutCallback);

		// prints start/stop for both stopwatches
		sw1.start().stop();
		sw2.start().stop();
		System.out.println();

		// we need to remove old callback
		manager.callback().removeCallback(stdoutCallback);
		// alternatively you can call this if you want to remove all callbacks
		SimonManager.callback().removeAllCallbacks();

		// filter callback is created
		CompositeFilterCallback filter = new CompositeFilterCallback();
		// rule to filter out all Simons matching pattern "other.*" is added
		filter.addRule(FilterRule.Type.MUST_NOT, null, "other.*");
		// original callback is added after this callback
		filter.addCallback(stdoutCallback);

		// filter callback is installed to the manager (with printing callback behind)
		manager.callback().addCallback(filter);

		// start/stop is printed only for sw1 because sw2 matches other.* pattern that is excluded (MUST_NOT)
		sw1.start().stop();
		sw2.start().stop();
	}
162336
public void close(Handler<AsyncResult<Void>> completion) {
        if (context == null) {
            context = vertx.getOrCreateContext();
        }

        context.runOnContext(v -> {
            if (http != null) {
                http.close(event -> {
                    logger.info("The server '{}' has been stopped (bound port: {})", name, port);
                    completion.handle(Future.<Void>succeededFuture());
                });
            }
        });
    }