Skip to main content

JSP edit from Eclipse without publish

2 replies [Last post]
cmathrusse
Offline
Joined: 2008-04-15

Each time I make an edit to a JSP page, from within Eclipse, I must publish to the server to be able to see my changes. This means the application must be rebuilt and deployed, over writing the existing application. This is a time consuming task as it takes my application about 2 minutes to deploy, due to the Web Services that are defined. wsgen must run during each deployment and 2 minutes is a pain to wait after each edit. When we were developing on Tomcat our jsp edits were see right away without having to republish the application.

Is there any way around this painful redeploy each time I edit a JSP?

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
cmathrusse
Offline
Joined: 2008-04-15

As a hack, I managed to learn that you can copy your JSP file into the deployed application of the GlassFish domains\domain1\applications\j2ee-apps directory. GlassFish will pick this up and compile it as soon as the page is accessed. This seems to me to be a real HACK to get around something that the plugin should provide. The Tomcat plugin supported this type of behavior right from Eclipse without any additional steps. Now I find myself making an edit from Eclipse and saving it. Then copying that file and replacing the deployed version of the file. Finally I access the page to see the changes.

WAY too much work!!!

mprabhat123
Offline
Joined: 2007-10-03

As cmathrusse has pointed correctly - To avoid publishing from eclipse you need to do two thngs -

1. Disable auto publish option from eclipse for glass fish.
2. Edit the deployed JSP in the glassfish domains\domain1\applications\j2ee-apps directory.

Cheers
PM