[jboss-user] [Installation, Configuration & Deployment] - Re: Is there a order in which jboss loads it's deployed appl

jaikiran do-not-reply at jboss.com
Wed Nov 8 08:32:47 EST 2006

anonymous wrote : Is there a order in which jboss loads it's deployed applications


anonymous wrote : and if so can this order be influenced? 

Yes again. There's a jboss-service.xml file in %JBOSS_HOME%/server/default/conf (replace "default", in this path, with whatever server configuration you are using) which specifies a URLComparator which is used by the DeploymentScanner for ordering the deployments.

Extract from that file:
anonymous wrote : 
  | The URLComparator can be used to specify a deployment ordering
  |            for deployments found in a scanned directory.  The class specified
  |            must be an implementation of java.util.Comparator, it must be able
  |            to compare two URL objects, and it must have a no-arg constructor.
  |            Two deployment comparators are shipped with JBoss:
  |              - org.jboss.deployment.DeploymentSorter
  |                Sorts by file extension, as follows:
  |                  "sar", "service.xml", "rar", "jar", "war", "wsr", "ear", "zip",
  |                  "*"
  |              - org.jboss.deployment.scanner.PrefixDeploymentSorter
  |                If the name portion of the url begins with 1 or more digits, those
  |                digits are converted to an int (ignoring leading zeroes), and
  |                files are deployed in that order.  Files that do not start with
  |                any digits will be deployed first, and they will be sorted by
  |                extension as above with DeploymentSorter.

By default it is set to org.jboss.deployment.DeploymentSorter. You can provide your own implementation if these 2 classes shipped by JBoss do not meet your requirements

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3984135#3984135

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3984135

More information about the jboss-user mailing list