It's not a secret anymore!
The moose likes JBoss and the fly likes Dependency between wars Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Products » JBoss
Reply Bookmark "Dependency between wars " Watch "Dependency between wars " New topic
Author

Dependency between wars

Anu Wadhwa
Greenhorn

Joined: Jul 28, 2009
Posts: 4
Hi,

I have an application runs fine on Jboss 4.2.3. I am trying to deploy it on Jboss 5.1.0.GA but having some issues with the order in which wars are deployed.
The wars need to be deployed in the order specified by application.xml.

application.xml
<application id="App_newproject-ear">
<display-name>newproject</display-name>
<module id="Module_auth-service.war">
<web>
<web-uri>auth-service.war</web-uri>
<context-root>authservice</context-root>
</web>
</module>
<module id="Module_newproject.war">
<web>
<web-uri>newproject.war</web-uri>
<context-root>newproject</context-root>
</web>
</module>
<module id="Module_dms.war">
<web>
<web-uri>dms.war</web-uri>
<context-root>newproject/DMS</context-root>
</web>
</module>
<module id="Module_webservices.war">
<web>
<web-uri>webservices.war</web-uri>
<context-root>newprojectWebServices</context-root>
</web>
</module>
......

jboss-app.xml
<jboss-app>
<module-order>strict</module-order>
</jboss-app>

I did some search and found out that module order strict doesn't work on Jboss 5.1. Can anyone tell me how do I specify dependency between wars?

Thanks.
Kees Jan Koster
Ranch Hand

Joined: Mar 31, 2009
Posts: 222
Dear Anu,

Wars should not be dependent. If you have that, your design is flawed (and you are not adhering to the servlet spec).

Please keep in mind that one war may not be deployed while another is, so there is no way to guarantee that they are both present and loaded. They may alse be deployed in separate containers.

If you have a dependency, you have to break it and change your app. Perhaps you can go through the database, or have one WAR call web services on the other. The absence of the other war is just something you will have to learn to live with.

Kees Jan


Java-monitor, JVM monitoring made easy (and free)
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Dependency between wars
 
Similar Threads
Error while publishing the WAS 6.0 Test Environment server
Problem understanding application.xml
Error while publishing Test Environment Server V6 in RAD 6
Loading sequence of the different modules in an EAR....?
failed to initialize bean container with "Null beannMetaData" error