Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jetty-dev] MBeanContainer keeps reference to servlets after they are undeployed

Hi,

I have found that:

WebAppContext app = new WebAppContext();
app.setContextPath(context);
app.setWar(warFile);
app.setClassLoader(new MyWebAppClassLoader(cl, app));
jetty.getHandler().addHandler(app);

app.stop();
jetty.getHandler().removeHandler(app);
app.destroy();

doesn't allow the webapp to be GCed if JMX is enabled.

The reason is that the MBeanContainer still has Container.Relationship
objects to the ServletHolders.

Ortwin


Back to the top