views:

518

answers:

3

Can we update a jar / war file in a deployed server and then reload the new jar / war file ? if so how simple we can achieve this, and please if possible list web servers which support this feature.

A: 

JBoss. Just drop in the files in the correct location.

Thorbjørn Ravn Andersen
thank you for your answer
Venkat
+1  A: 

Both Tomcat and Jetty will support a hot deploy. They simply monitor the deploy directory for changes, so you can just copy the .war file into that directory, and the server will undeploy/redeploy.

Brian Agnew
thanks a lot for answering my question :)
Venkat
Can Tomcat deploy jars?
Thorbjørn Ravn Andersen
I don't believe so. I'm only looking at .wars. Where would you drop a .jar ? It's not a web app in itself, so are you looking to redeploy a common lib ?
Brian Agnew
+1  A: 

Yes.

All major Java EE Servlet containers support this. All that I've worked with anyway, which includes Glassfish, Tomcat, WebSphere, WebLogic and JRun.

I haven't used the other Oracle container, but I would think it does too.

That said, none of them support it all that reliably (they'll detect most changes, but there are certain types of class changes that will always require a restart), unless you're using JavaRebel underneath.

Jack Leow