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

    Barrier not started in cluster using JBoss 5.0.0.GA

    Zana Jaf Newbie

      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:


      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}
       -> 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">

      Is this a right solution/workaround?