Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-17990

[GSS](7.3.z) WFLY-12778 - EAR deployed on colocated master/slave servers does not wait for the embedded JMS services to startup properly

    XMLWordPrintable

Details

    • Bug
    • Resolution: Not a Bug
    • Major
    • None
    • 7.1.6.GA, 7.2.3.GA, 7.3.0.CD17
    • ActiveMQ
    • None
    • +
    • Hide

      Use an external pooled connection factory as a configuration workaround:

      For example, using helloworld-mdb as a reproducer, with following configuration the issue doesn't manifest anymore:

      /subsystem=messaging-activemq/in-vm-connector=in-vm-remote:add(server-id=0)
      /subsystem=messaging-activemq/pooled-connection-factory=activemq-ra-remote:add(connectors=[in-vm-remote], entries=["java:/RemoteJmsXA", "java:jboss/RemoteJmsXA"])
      /subsystem=messaging-activemq/external-jms-queue=HelloWorldMDBQueue:add(entries=["java:/queue/HELLOWORLDMDBQueue"])
      /subsystem=messaging-activemq/external-jms-topic=HelloWorldMDBTopic:add(entries=["java:/topic/HELLOWORLDMDBTopic"])
      
      /subsystem=messaging-activemq/server=default/jms-queue=HelloWorldMDBQueue:add(entries=["java:/queue/int/HELLOWORLDMDBQueue"])
      /subsystem=messaging-activemq/server=default/jms-topic=HelloWorldMDBTopic:add(entries=["java:/topic/int/HELLOWORLDMDBTopic"])
      
      /subsystem=ee/service=default-bindings:write-attribute(name=jms-connection-factory, value="java:jboss/RemoteJmsXA")
      /subsystem=ejb3:write-attribute(name=default-resource-adapter-name, value="activemq-ra-remote")
      
      reload
      Show
      Use an external pooled connection factory as a configuration workaround: For example, using helloworld-mdb as a reproducer, with following configuration the issue doesn't manifest anymore: /subsystem=messaging-activemq/in-vm-connector=in-vm-remote:add(server-id=0) /subsystem=messaging-activemq/pooled-connection-factory=activemq-ra-remote:add(connectors=[in-vm-remote], entries=[ "java:/RemoteJmsXA" , "java:jboss/RemoteJmsXA" ]) /subsystem=messaging-activemq/external-jms-queue=HelloWorldMDBQueue:add(entries=[ "java:/queue/HELLOWORLDMDBQueue" ]) /subsystem=messaging-activemq/external-jms-topic=HelloWorldMDBTopic:add(entries=[ "java:/topic/HELLOWORLDMDBTopic" ]) /subsystem=messaging-activemq/server= default /jms-queue=HelloWorldMDBQueue:add(entries=[ "java:/queue/ int /HELLOWORLDMDBQueue" ]) /subsystem=messaging-activemq/server= default /jms-topic=HelloWorldMDBTopic:add(entries=[ "java:/topic/ int /HELLOWORLDMDBTopic" ]) /subsystem=ee/service= default -bindings:write-attribute(name=jms-connection-factory, value= "java:jboss/RemoteJmsXA" ) /subsystem=ejb3:write-attribute(name= default -resource-adapter-name, value= "activemq-ra-remote" ) reload
    • Hide

      1. Create 2 colocated servers. Server 1 will have master1 and slave2 while Server2 will have master2 and slave1

      2. Start both servers with standalone-full-ha.xml.

      3. Stop Server 1.

      4. Put an EAR with an MDB in the deployment directory of Server 1

      5. Start Server1

      At this point you'll see these errors in Server1 logs:

      14:48:11,134 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("deploy") failed - address: ([("deployment" => "EJB_MDBEAR.ear")]) - failure description: {
          "WFLYCTL0412: Required services that are not installed:" => [
              "jboss.ra.activemq-ra",
              "jboss.naming.context.java.jboss.DefaultJMSConnectionFactory"
          ],
          "WFLYCTL0180: Services with missing/unavailable dependencies" => [
              "jboss.naming.context.java.comp.EJB_MDBEAR.EJB_MDB.TestMDB.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]",
              "jboss.deployment.subunit.\"EJB_MDBEAR.ear\".\"EJB_MDB.jar\".component.TestMDB.CREATE is missing [jboss.ra.activemq-ra]",
              "jboss.naming.context.java.module.EJB_MDBEAR.EJB_MDB.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]"
          ]
      }
      
      
      Show
      1. Create 2 colocated servers. Server 1 will have master1 and slave2 while Server2 will have master2 and slave1 2. Start both servers with standalone-full-ha.xml. 3. Stop Server 1. 4. Put an EAR with an MDB in the deployment directory of Server 1 5. Start Server1 At this point you'll see these errors in Server1 logs: 14:48:11,134 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread ) WFLYCTL0013: Operation ( "deploy" ) failed - address: ([( "deployment" => "EJB_MDBEAR.ear" )]) - failure description: { "WFLYCTL0412: Required services that are not installed:" => [ "jboss.ra.activemq-ra" , "jboss.naming.context.java.jboss.DefaultJMSConnectionFactory" ], "WFLYCTL0180: Services with missing/unavailable dependencies" => [ "jboss.naming.context.java.comp.EJB_MDBEAR.EJB_MDB.TestMDB.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]" , "jboss.deployment.subunit.\" EJB_MDBEAR.ear\ ".\" EJB_MDB.jar\ ".component.TestMDB.CREATE is missing [jboss.ra.activemq-ra]" , "jboss.naming.context.java.module.EJB_MDBEAR.EJB_MDB.DefaultJMSConnectionFactory is missing [jboss.naming.context.java.jboss.DefaultJMSConnectionFactory]" ] }

    Description

      When an EAR containing MDBS is deployed in one of the colocated master/slave servers, the application does not wait for the embedded broker to start up and generates these errors in the logs:

      /14:48:11,134 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("deploy") failed - address: ([("deployment" => "EJB_MDBEAR.ear")]) - failure description: {
          "WFLYCTL0412: Required services that are not installed:" => [
              "jboss.ra.activemq-ra",
              "jboss.naming.context.java.jboss.DefaultJMSConnectionFactory"
          ],
      
      

      When the broker is eventually started, these MDBs get deployed and start working fine without any redeployment but these errors are not desirable in the logs.
      Defining the resource-ref in ejb-jar.xml or annotating with @Resource does not help either.

      The application should wait for its dependencies to be available.

      Attachments

        Issue Links

          Activity

            People

              spyrkob Bartosz Spyrko-Smietanko
              spyrkob Bartosz Spyrko-Smietanko
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: