Show Table of Contents
10.7. Control the order of Deployed Applications on JBoss EAP 6
JBoss EAP 6 offers fine grained control over the order of deployment of applications when the server is started. Strict order of deployment of applications present in multiple ear files can be enabled along with persistence of the order after a restart.
Procedure 10.15. Control the order of deployment in EAP 6.0.X
- Create CLI scripts that will deploy and undeploy the applications in sequential order when the server is started/stopped.
- CLI also supports the concept of batch mode which allows you to group commands and operations and execute them together as an atomic unit. If at least one of the commands or operations fails, all the other successfully executed commands and operations in the batch are rolled back.
Procedure 10.16. Control the order of deployment in EAP 6.1.X and later
A new feature in EAP 6.1.X and later named Inter Deployment Dependencies allows you to declare dependencies between top level deployments.
- Create (if it doesn't exist) a
jboss-all.xmlfile in theapp.ear/META-INFfolder, whereapp.earis the application archive that depends on another application archive to be deployed before it is. - Make a
jboss-deployment-dependenciesentry in this file as shown below. Note that in the listing below,framework.earis the dependency application archive that should be deployed beforeapp.earapplication archive is.<jboss umlns="urn:jboss:1.0"> <jboss-deployment-dependencies xmlns="urn:jboss:deployment-dependencies:1.0"> <dependency name="framework.ear" /> </jboss-deployment-dependencies> </jboss>

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.