protected void destroyContainer() { container.destroy(); container = null; }
private void destroyServletContainer() { ClassLoader currentThreadClassLoader = Thread.currentThread().getContextClassLoader(); Thread.currentThread().setContextClassLoader(chainingClassLoader); try { servletContainer.destroy(); SLF4J_BRIDGE.uninstall(); } finally { Thread.currentThread().setContextClassLoader(currentThreadClassLoader); } }
protected synchronized void reloadContainer() throws ServletException { // reload is not working correctly since old classes are still referenced // for this to work we need a custom ResourceConfig but all fields in jersey // classes are private so we cannot set it ... try { container.destroy(); container = createServletContainer(app); container.init(getServletConfig()); } finally { isDirty = false; } }