2 Replies Latest reply on Jan 7, 2009 3:28 AM by zana

    Barrier not started in cluster using JBoss 5.0.0.GA

      We are using the Barrier mbean to deploy some of our services as singletons in a cluster. Currently we use JBoss 4.2.3 in a cluster of two nodes, and the singletons are working properly, their configuration includes the following dependency:

      <depends>jboss.ha:service=HASingletonDeployer,type=Barrier</depends>


      When I try to use this dependency in JBoss 5.0.0.GA, the deployment fails because the Barrier is never started, it is only brought to the 'Create' state.

      The log shows:
      2009-01-05 10:05:47,651 DEBUG [BarrierController] (main:) [SubscriptionInfo { objectName='jboss.ha:service=HASingletonDeployer', handback=start, filter=javax.management.NotificationFilterSupport@110faff }, SubscriptionInfo { objectName='jboss.ha:service=HASingletonDeployer', handback=stop, filter=javax.management.NotificationFilterSupport@1ce7ceb }]
      2009-01-05 10:05:47,651 DEBUG [BarrierController] (main:) Subscribing for JMX notifications, dynamic=false
      2009-01-05 10:05:47,651 DEBUG [BarrierController] (main:) Could not subscribe to: 'jboss.ha:service=HASingletonDeployer', target or listener MBean not registered
      2009-01-05 10:05:47,651 DEBUG [BarrierController] (main:) Could not subscribe to: 'jboss.ha:service=HASingletonDeployer', target or listener MBean not registered
      2009-01-05 10:05:47,651 DEBUG [BarrierController] (main:) Created jboss.ha:service=HASingletonDeployer,type=BarrierControllerMBean
      2009-01-05 10:05:47,651 DEBUG [ServiceController] (main:) Creating service jboss.ha:service=HASingletonDeployer,type=BarrierControllerMBean
      ...
      ...
      2009-01-05 10:05:47,653 DEBUG [BarrierController] (main:) Starting jboss.ha:service=HASingletonDeployer,type=BarrierControllerMBean
      2009-01-05 10:05:47,653 DEBUG [BarrierController] (main:) Started jboss.ha:service=HASingletonDeployer,type=BarrierControllerMBean
      2009-01-05 10:05:47,654 DEBUG [ServiceController] (main:) starting service jboss.ha:service=HASingletonDeployer,type=BarrierControllerMBean
      ...
      ...
      2009-01-05 10:06:28,791 ERROR [ProfileServiceBootstrap] (main:) Failed to load profile: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):
      
      *** CONTEXTS MISSING DEPENDENCIES: Name -> Dependency{Required State:Actual State}
      
      UserXS:service=myService
       -> jboss.ha:service=HASingletonDeployer,type=Barrier{Start:Create}
      
      *** CONTEXTS IN ERROR: Name -> Error
      
      jboss.ha:service=HASingletonDeployer,type=Barrier -> Create
      
      


      From what I see in the log, it seems that the BarrierController tries to subscribe to jmx notifications from HASingletonDeployer before the latter is registered.

      I am using the original all/deploy/cluster/deploy-hasingleton-jboss-beans.xml file without changes.

      Is this a known issue?

      The error disappears and the Barrier gets started when I add a dependency to the BarrierController in deploy-hasingleton-jboss-beans.xml
      <bean class="org.jboss.system.BarrierController" name="jboss.ha:service=HASingletonDeployer,type=BarrierController">
      ...
       <depends>jboss.ha:service=HASingletonDeployer</depends>
      ...
      
      



      Is this a right solution/workaround?

      Thanks.