本文整理了Java中org.eclipse.jetty.server.Server.stop()
方法的一些代码示例,展示了Server.stop()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Server.stop()
方法的具体详情如下:
包路径:org.eclipse.jetty.server.Server
类名称:Server
方法名:stop
暂无
代码示例来源:origin: spring-projects/spring-framework
public void stop() throws Exception {
this.server.stop();
}
代码示例来源:origin: perwendel/spark
/**
* {@inheritDoc}
*/
@Override
public void extinguish() {
logger.info(">>> {} shutting down ...", NAME);
try {
if (server != null) {
server.stop();
}
} catch (Exception e) {
logger.error("stop failed", e);
System.exit(100); // NOSONAR
}
logger.info("done");
}
代码示例来源:origin: AsyncHttpClient/async-http-client
@AfterMethod(alwaysRun = true)
public void tearDownGlobal() throws Exception {
server.stop();
server2.stop();
}
代码示例来源:origin: AsyncHttpClient/async-http-client
@AfterClass(alwaysRun = true)
public void tearDownGlobal() throws Exception {
httpServer.stop();
proxy.stop();
}
代码示例来源:origin: AsyncHttpClient/async-http-client
@AfterClass(alwaysRun = true)
public void tearDownGlobal() throws Exception {
server.stop();
server2.stop();
}
代码示例来源:origin: AsyncHttpClient/async-http-client
@AfterClass(alwaysRun = true)
public void tearDownGlobal() throws Exception {
if (server != null) {
server.stop();
}
}
代码示例来源:origin: AsyncHttpClient/async-http-client
@AfterClass(alwaysRun = true)
public void tearDownGlobal() throws Exception {
for (Server srv : servers) {
srv.stop();
}
}
代码示例来源:origin: AsyncHttpClient/async-http-client
@Override
public void close() throws IOException {
if (server != null) {
try {
server.stop();
} catch (Exception e) {
throw new IOException(e);
}
}
}
代码示例来源:origin: apache/incubator-druid
@After
public void tearDown() throws Exception
{
coordinator.stop();
overlord.stop();
coordinatorExpectedRequest.reset();
overlordExpectedRequest.reset();
}
代码示例来源:origin: spring-projects/spring-framework
@AfterClass
public static void stopJettyServer() throws Exception {
if (jettyServer != null) {
jettyServer.stop();
}
}
代码示例来源:origin: spring-projects/spring-framework
@AfterClass
public static void stopServer() throws Exception {
if (server != null) {
server.stop();
}
}
代码示例来源:origin: AsyncHttpClient/async-http-client
@AfterClass(alwaysRun = true)
public void tearDownGlobal() throws Exception {
super.tearDownGlobal();
server2.stop();
serverNoAuth.stop();
}
代码示例来源:origin: apache/incubator-dubbo
@Override
public void close() {
super.close();
//
ServletManager.getInstance().removeServletContext(url.getParameter(Constants.BIND_PORT_KEY, url.getPort()));
if (server != null) {
try {
server.stop();
} catch (Exception e) {
logger.warn(e.getMessage(), e);
}
}
}
代码示例来源:origin: apache/incubator-dubbo
@Override
public void close() {
super.close();
//
ServletManager.getInstance().removeServletContext(url.getParameter(Constants.BIND_PORT_KEY, url.getPort()));
if (server != null) {
try {
server.stop();
} catch (Exception e) {
logger.warn(e.getMessage(), e);
}
}
}
代码示例来源:origin: AsyncHttpClient/async-http-client
@AfterClass(alwaysRun = true)
public void tearDownGlobal() throws Exception {
super.tearDownGlobal();
server2.stop();
}
代码示例来源:origin: apache/incubator-druid
@After
public void tearDown() throws Exception
{
client.close();
clientLosAngeles.close();
server.stop();
walker.close();
walker = null;
client = null;
clientLosAngeles = null;
server = null;
}
代码示例来源:origin: spring-projects/spring-framework
@Override
protected void resetInternal() {
try {
if (this.jettyServer.isRunning()) {
this.jettyServer.setStopTimeout(5000);
this.jettyServer.stop();
this.jettyServer.destroy();
}
}
catch (Exception ex) {
throw new IllegalStateException(ex);
}
finally {
this.jettyServer = null;
this.contextHandler = null;
}
}
代码示例来源:origin: spring-projects/spring-framework
@Override
public void stop() throws Exception {
try {
if (this.contextHandler.isRunning()) {
this.contextHandler.stop();
}
}
finally {
if (this.jettyServer.isRunning()) {
this.jettyServer.setStopTimeout(5000);
this.jettyServer.stop();
}
}
}
代码示例来源:origin: Netflix/eureka
@AfterClass
public static void tearDown() throws Exception {
removeEurekaConfiguration();
if (jerseyReplicationClient != null) {
jerseyReplicationClient.shutdown();
}
if (server != null) {
server.stop();
}
if (httpClientFactory != null) {
httpClientFactory.shutdown();
}
}
代码示例来源:origin: spring-projects/spring-framework
@Override
protected void stopInternal() throws Exception {
try {
if (this.contextHandler.isRunning()) {
this.contextHandler.stop();
}
}
finally {
try {
if (this.jettyServer.isRunning()) {
this.jettyServer.setStopTimeout(5000);
this.jettyServer.stop();
this.jettyServer.destroy();
}
}
catch (Exception ex) {
// ignore
}
}
}
内容来源于网络,如有侵权,请联系作者删除!