0 Replies Latest reply on Dec 6, 2011 4:49 AM by Li hui

    Deployment order for multiple war(Jboss 7)

    Li hui Newbie

      Hello !

       

      I'm going through a migration from JBoss as6 to JBoss as7

       

      My EAR contains multiple wars : one is called tx_init.war and need to be deployed first,

      another is called tx_admin.war and need to be called last.

       

      How can I configure this ?

       

      ========================

       

      application.xml

       

      <?xml version="1.0" encoding="UTF-8"?>

      <application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:application="http://java.sun.com/xml/ns/javaee/application_6.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_6.xsd" id="Application_ID" version="6">

        <display-name>tx_ear</display-name>

        <initialize-in-order>true</initialize-in-order>

        <module>

          <web>

            <web-uri>tx_admin.war</web-uri>

            <context-root>tx_admin</context-root>

          </web>

        </module>

        <module>

          <web>

            <web-uri>tx_init.war</web-uri>

            <context-root>tx_init</context-root>

          </web>

        </module>

      </application>

       

      jboss-app.xml

       

      <?xml version="1.0" encoding="UTF-8" ?>
      <!DOCTYPE jboss-app  PUBLIC "-//JBoss//DTD Java EE Application 5.0//EN"
        "http://www.jboss.org/j2ee/dtd/jboss-app_5_0.dtd">

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

       

      </jboss-app>

       

      log:

       

      17:32:27,487 情報    [org.jboss.modules] JBoss Modules version 1.0.2.GA
      17:32:31,174 INFO  [org.jboss.msc] JBoss MSC version 1.0.1.GA
      17:32:31,612 INFO  [org.jboss.as] JBoss AS 7.0.2.Final "Arc" starting
      17:32:41,939 WARN  [org.jboss.as] No security realm defined for native management service, all access will be unrestricted.
      17:32:42,002 INFO  [org.jboss.as] creating http management service using network interface (management) port (9990)
      17:32:42,018 WARN  [org.jboss.as] No security realm defined for http management service, all access will be unrestricted.
      17:32:42,033 INFO  [org.jboss.as.logging] Removing bootstrap log handlers
      17:32:42,361 INFO  [org.jboss.as.connector.subsystems.datasources] (Controller Boot Thread) Deploying JDBC-compliant driver class org.h2.Driver (version 1.2)
      17:32:42,627 INFO  [org.jboss.as.clustering.infinispan.subsystem] (Controller Boot Thread) Activating Infinispan subsystem.
      17:32:43,627 INFO  [org.jboss.as.naming] (Controller Boot Thread) JBAS011800: Activating Naming Subsystem
      17:32:43,861 INFO  [org.jboss.as.naming] (MSC service thread 1-2) JBAS011802: Starting Naming Service
      17:32:43,986 INFO  [org.jboss.as.osgi] (Controller Boot Thread) JBAS011910: Activating OSGi Subsystem
      17:32:44,346 INFO  [org.jboss.as.security] (Controller Boot Thread) Activating Security Subsystem
      17:32:44,674 INFO  [org.jboss.remoting] (MSC service thread 1-1) JBoss Remoting version 3.2.0.Beta2
      17:32:45,127 INFO  [org.xnio] (MSC service thread 1-1) XNIO Version 3.0.0.Beta3
      17:32:45,299 INFO  [org.xnio.nio] (MSC service thread 1-1) XNIO NIO Implementation Version 3.0.0.Beta3
      17:32:47,095 INFO  [org.apache.catalina.core.AprLifecycleListener] (MSC service thread 1-4) The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\eclipse\jdk1.7.0_01\jre\bin;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;native;.
      17:32:47,283 INFO  [org.jboss.as.ee] (Controller Boot Thread) Activating EE subsystem
      17:32:47,502 INFO  [org.jboss.as.jmx.JMXConnectorService] (MSC service thread 1-4) Starting remote JMX connector
      17:32:48,002 INFO  [org.jboss.as.remoting] (MSC service thread 1-2) Listening on /127.0.0.1:9999
      17:32:48,533 INFO  [org.apache.coyote.http11.Http11Protocol] (MSC service thread 1-2) Coyote HTTP/1.1を http--127.0.0.1-8080 で起動します
      17:32:50,423 INFO  [org.jboss.as.connector] (MSC service thread 1-3) Starting JCA Subsystem (JBoss IronJacamar 1.0.3.Final)
      17:32:50,986 ERROR [org.jboss.remoting.remote] (XNIO NIO Read 1) JBREM00200: Remote connection failed: java.io.IOException: 確立された接続がホスト コンピュータのソウトウェアによって中止されました。
      17:32:51,080 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-4) Bound data source [java:jboss/datasources/ExampleDS]
      17:32:51,798 WARN  [org.jboss.as.protocol] (pool-2-thread-9) JBAS012100: Got error closing channel JBREM00206: Channel is not open
      17:32:52,689 WARN  [org.jboss.as.protocol] (pool-2-thread-4) JBAS012100: Got error closing channel JBREM00206: Channel is not open
      17:32:53,236 INFO  [org.jboss.as.deployment] (MSC service thread 1-3) Started FileSystemDeploymentService for directory C:\eclipse_new\jboss-as-7.0.2.Final\standalone\deployments
      17:32:53,283 INFO  [org.jboss.as.deployment] (DeploymentScanner-threads - 1) Found tx_ear.ear in deployment directory. To trigger deployment create a file called tx_ear.ear.dodeploy
      17:32:53,392 INFO  [org.jboss.as] (Controller Boot Thread) JBoss AS 7.0.2.Final "Arc" started in 28358ms - Started 94 of 149 services (55 services are passive or on-demand)
      17:32:53,455 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-2) Starting deployment of "tx_ear.ear"
      17:32:54,173 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-2) Starting deployment of "tx_init.war"
      17:32:54,173 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-1) Starting deployment of "tx_admin.war"
      17:32:55,814 INFO  [org.jboss.as.jpa] (MSC service thread 1-1) added javax.persistence.api dependency to tx_ear.ear
      17:32:55,814 INFO  [org.jboss.as.jpa] (MSC service thread 1-1) added javax.persistence.api dependency to tx_admin.war
      17:32:55,814 INFO  [org.jboss.as.jpa] (MSC service thread 1-4) added javax.persistence.api dependency to tx_init.war
      17:32:57,345 INFO  [stdout] (MSC service thread 1-3) ===========Start===========class com.admin.AdminListener:2011-12-06 17:32:57.00345

      17:32:57,345 INFO  [stdout] (MSC service thread 1-4) =======start===============class com.init.InitListener:2011-12-06 17:32:57.00345

      17:33:03,345 INFO  [stdout] (MSC service thread 1-3) ===========end===========class com.admin.AdminListener:2011-12-06 17:33:03.00345

      17:33:03,891 INFO  [org.jboss.web] (MSC service thread 1-3) registering web context: /tx_admin
      17:33:04,345 INFO  [stdout] (MSC service thread 1-4) =======end===============class com.init.InitListener:2011-12-06 17:33:04.00345

      17:33:04,345 INFO  [org.jboss.web] (MSC service thread 1-4) registering web context: /tx_init
      17:33:04,516 INFO  [org.jboss.as.server.controller] (DeploymentScanner-threads - 2) Deployed "tx_ear.ear"