1 Reply Latest reply on Oct 13, 2011 4:27 AM by sharad Srivastava

    Monitor alerts depending on jboss.web not deploying

    tek no Novice

      I have created a monitor on the number of busy threads tomcat is using. When I restart jboss I get

      ObjectName: jboss.monitor:service=Busy_Thread_Count
       State: FAILED
       Reason: javax.management.InstanceNotFoundException: jboss.web:type=ThreadPool,name=http-0.0.0.0-80 is not registered.
       I Depend On:
       jboss.alerts:service=ConsoleAlertListener
      


      The problem appears that jboss tries to deploy the mbean before tomcat is ready
      2007-02-15 13:54:35,349 WARN [org.jboss.system.ServiceController] Problem starting service jboss.monitor:service=Busy_Thread_Count
      javax.management.InstanceNotFoundException: jboss.web:type=ThreadPool,name=http-0.0.0.0-80 is not registered.
       at org.jboss.mx.server.registry.BasicMBeanRegistry.get(BasicMBeanRegistry.java:523)
       at org.jboss.mx.server.MBeanServerImpl.getAttribute(MBeanServerImpl.java:550)
       at org.jboss.monitor.ThresholdMonitor.startService(ThresholdMonitor.java:110)
       at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
       at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
       at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
       at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
       at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
       at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
       at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
       at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
       at $Proxy0.start(Unknown Source)
      
      
      


      The mbean is defined as
      ?xml version="1.0" encoding="UTF-8"?>
      <server>
      <mbean code="org.jboss.monitor.ThresholdMonitor"
       name="jboss.monitor:service=Busy_Thread_Count">
       <attribute name="MonitorName">Busy Thread Count</attribute>
       <attribute name="ObservedObject">jboss.web:type=ThreadPool,name=http-0.0.0.0-80</attribute>
       <attribute name="ObservedAttribute">currentThreadsBusy</attribute>
       <depends-list optional-attribute-name="AlertListeners">
       <depends-list-element>jboss.alerts:service=ConsoleAlertListener </depends-list-element>
       </depends-list>
       <attribute name="Threshold">100</attribute>
       <attribute name="Period">10000</attribute>
       <attribute name="CompareTo">-1</attribute>
       <attribute name="Enabled">true</attribute>
      </mbean>
      </server>
      


      Clearly, there is no dependency on jboss.web defined. Will this bug be addressed?

      thank you