Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Glassfish taking 20s to do hot deployment, is that right?

I'm working in a JSF project with Eclipse and Glassfish 3.1.2. Every time I did a minor change and save it, Glassfish do the hot deployment, but is taking too much time to do that, about 20s, at least.

Can I do something do deacrease this time ? Is horrible develop something where you have to wait all time time everytime I change something.

UPDATE This is how my project settings.

enter image description here

Just open the folder below, this surprise me, is this so many .jar files, is this correct ?

enter image description here

And this one:

enter image description here

My Glassfish configuration :

enter image description here Any idea ?

like image 799
Valter Silva Avatar asked Nov 03 '22 22:11

Valter Silva


1 Answers

There are several ways to deploy a GlassFish application. To speed up development/debuging we need a way to instantly deploy web applications. One of the ways is to use hot deployment feature, another lesser known feature is ‘directory deployment’. You simply point GlassFish to your development directory and let it pick up and deploy application from there. No packaging and re-deoploying hassles. The catch is whenever you want to re-deploy your application you just need to touch a file called .reload which should be present in your web folder. Following is the command and directory structure you can use.

–|myproj
–|–|src
–|–|web
–|–|–|WEB-INF
–|–|–|–lib
–|–|–|–classes
–|–|–|–web.xml
–|–|.reload

GLASS_FISH_HOME/bin/asadmin deploydir full_path_to_you_web_folder

like image 51
Anass Avatar answered Nov 15 '22 09:11

Anass