Directory Deployment from NetBeans to GlassFish
By vbkraemer on Mar 17, 2008
I published a teaser entry, where I demonstrated the effect of a code change related to directory deployment that I had pushed a couple days before. Since the entry was exposition "thin", I have gotten some questions about it...
After reading through the questions, I figured it would be easy to google up some reference and post them....
Boy, was I wrong!
I hope that this entry will answer the questions and be a "hit" for folks interested in NetBeans, directory deployment and GlassFish. The synonym for directory deployment in the JBoss user community appears to be 'exploded deployment'. The synonym for directory deployment in the WebLogic user community appears to be 'deployment of exploded archive directories'.
When a project is directory deployed into a web container, like Tomcat, or an app server, like GlassFish, a lot of optimizations can occur.
- packaging the module or app becomes unnecessary.
No archive is created.
- unpacking the module or app becomes unnecessary.
No archive needs to be read and/or transfered and exploded.
- JSP changes are detectable, if the IDE forwards source changes into the 'deployment directory'.
NetBeans pushes changes to html and jsp files to the deploy directory. Both servers detect the updates when the page is requested and do the necessary work to display the current content.
NetBeans supports directory deployment of Web Application projects to Tomcat and GlassFish. This has been available for quite some time. I found this reference that alludes to directory deployment with NB 3.6 and Sun Java System Application Server 8.0. NetBeans was extended to support directory deployment of ears and ejb-jars onto GlassFish V2 in the NetBeans 6.0 release.
The other server integration plugins for NetBeans 6.0.1 or NetBeans 6.1 (recently beta'ed) do not support directory deployment.
The recent changes that improve the performance of 'Run Project' and 'Run File' for a JSP file change in web applications and web applications embedded in an enterprise application are available in nightly builds of NetBeans 6.1.
I hope to integrate some of the ideas from a blog entry by JFA in the next few days. This will make even more web-app change scenarios faster.