3 Replies Latest reply on Jun 24, 2003 2:41 PM by rboston

    Can't find either ServiceMBeanSupport or Service

    rboston

      Running 3.0.4 of JBOSS, I've a couple of simple MBeans running. By themselves they work great but when I try to hook them into the JBoss MBean lifecycle I get class not found exceptions on deployment.
      I first tried implementing Service and got the errors.
      Then I tried extending ServiceMBeanSupport and got the errors.

      The strange part is that the classes are
      org.jboss.system.ServiceMBeanSupport
      and
      org.jboss.system.Service

      I don't see how it's possible since they are in jboss-system.jar. I've searched the archives but only found things from 2001.

      Has anybody hit this problem recently and solved it??

        • 1. Re: Can't find either ServiceMBeanSupport or Service

          Sounds like you've modified the classpath
          instead of putting your classes in
          server/[config]/deploy or server/[config]/lib

          Regards,
          Adrian

          • 2. Re: Can't find either ServiceMBeanSupport or Service
            rboston

            Nope the classpath is the same.

            Some of the Mbeans that give the error messages are in server/[config]/deploy contained within an sar.

            server/[config]/lib only contains jboss jars currently.

            It just seems bizarre and shouldn't be happening unless there's some class loader issue.

            • 3. Re: Can't find either ServiceMBeanSupport or Service
              rboston

              Adrian

              Thanks. After digging a little deeper I found that 99.9% of the classes in question are in the deploy or lib directory.
              There is one wrapper class that extends ServiceMBeanSupport. This class happens to be in the classpath rather than the individual jars. This is simply for code reuse and package simplification.
              By moving this class into each of the jars/sars/ears in question the problem is resolved.

              Thanks again.