Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] dynamic reloading in dev environment

Since you seem to be using classic deployments and WebAppContext, then you are using ClassLoaders (2 of them in fact).
It will be exceedingly difficult to not use classloaders, as that's a core / fundamental part of the various specs that Jetty implements.

Then you also have the various class pinning issues that prevent clean and dynamic unload/reload of classes.
See also
Those prevent leaks in the WebApp class reloading by forcing the class pinning at the server level.

Using something like dcevm will do you no good, as the reloading is for the webapp, not the server.
And dcevm is focused on the system/server classes, which is too fundamental.

Joakim Erdfelt <joakim@xxxxxxxxxxx>
Expert advice, services and support from from the Jetty & CometD experts

On Tue, Dec 16, 2014 at 7:38 AM, Edgar Espina <espina.edgar@xxxxxxxxx> wrote:

  I want to implement a "dynamic reloading of classes" for my micro-webframework, but I want to get out of class loaders (if possible).

 I will recommend users to install and use, which alredy does the hard part (class reloading at the JVM level) and avoid a custom class loader. 

 In my mind, all I have to do is listening for changes and restart the framework (when need it). Today,
I can't to do it because calling server.stop, exit the JVM (of course).

 I've been reviewing the deployment plugin from Jetty. But not sure if the deployment plugin required a custom classloader or not. Also, want this ONLY for development (not prod). That's why I think current deployment plugin is too much for my use case.

 You can see how I do build a my server here:

I will love to hear what do you think is possible or not, alternative solutions or any other comment.

Thanks in advance

jetty-users mailing list
To change your delivery options, retrieve your password, or unsubscribe from this list, visit

Back to the top