Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to run a server (.war) file separate from application (another .war)

 
Shannon Sims
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello and thanks for reading my post.

I am running an application on JBoss 5.1. I want to run the server separate from the application, so if I shut down the application, the server is not impacted by it. How do I do this?

Thanks!

My environment: Windows 7, Java 1.6, JBoss 1.5, Eclipse Helios.
 
Greg Charles
Sheriff
Posts: 2985
12
Firefox Browser IntelliJ IDE Java Mac Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If by shut down you mean undeploy, then undeploying one war shouldn't affect the running of another.
 
Shannon Sims
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Greg. Thanks for your answer. So, it would also be safe to assume, stopping the application should have no impact to the server, correct? If my application is in the /default/deploy directory, does it make sense for my server to reside in the default directory too? I'm not too familiar with the in/outs of JBoss, so I appreciate your feedback.
 
Greg Charles
Sheriff
Posts: 2985
12
Firefox Browser IntelliJ IDE Java Mac Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's been a while since I used JBoss 5, but I believe the /server/default/deploy directory is where JBoss looks for wars or ears to hot deploy. So if you put the wars there, they will deploy automatically (even if JBoss is already running) and if you remove the wars, they will undeploy. If you put them anywhere else, you have to issues commands to JBoss to deploy or undeploy them. The hot deploy feature is configurable, but I think the default configuration has hot deploy turned on, and scanning for changes in the /server/default/deploy directory every 10 seconds or so for any changes.
 
Shannon Sims
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Greg for your feedback. I'll give it a try and put the .war into the default directory.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic