Skip to content

Commit

Permalink
修复shutdown的时候访问的不是ProxyCoreServer的BUG
Browse files Browse the repository at this point in the history
虽然目前版本不会有什么问题,但未来就不好说
  • Loading branch information
杜琨 committed Mar 22, 2018
1 parent f2b474a commit 9cf89a3
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,10 @@ private void shutdownServer(final ClassLoader sandboxClassLoader)
return;
}

final Class<?> classOfJettyCoreServer = sandboxClassLoader
.loadClass("com.alibaba.jvm.sandbox.core.server.jetty.JettyCoreServer");
final Object objectOfJettyCoreServer = classOfJettyCoreServer.getMethod("getInstance").invoke(null);
final Method methodOfDestroy = classOfJettyCoreServer.getMethod("destroy");
final Class<?> classOfCoreServer = sandboxClassLoader
.loadClass("com.alibaba.jvm.sandbox.core.server.ProxyCoreServer");
final Object objectOfJettyCoreServer = classOfCoreServer.getMethod("getInstance").invoke(null);
final Method methodOfDestroy = classOfCoreServer.getMethod("destroy");
methodOfDestroy.invoke(objectOfJettyCoreServer, null);
logger.info("shutdown http-server success, for shutdown jvm-sandbox.");
}
Expand Down

0 comments on commit 9cf89a3

Please sign in to comment.