3 Replies Latest reply on Jun 17, 2008 11:20 AM by csaldanh

    Migration: 3.2.0 to 4.2.2 (org.jboss.jmx.adaptor.rmi.RMIAdap

      We are currently migrating from JBoss 3.2.0 to 4.2.2 and the registerMBean() method from the org.jboss.jmx.adaptor.rmi.RMIAdaptor interface seems to have been removed (getting compile error on the method).

      This is our current method to register the JBoss scheduler:

      public void registerSchedule() throws SchedulerException {
      unregisterSchedule(false); // just in case
      try {
      server.registerMBean(this, scheduleName);
      } catch (Exception e) {
      throw new SchedulerException(e.getMessage(), e);
      }
      }

      The registerMBean method has been removed from the RMIAdaptor interface and thus fails to compile:
      server.registerMBean(this, scheduleName);

      We were wondering if this should be replaced by the createMBean method (from the javax.management.MBeanServerConnection super-interface of RMIAdaptor) as follows:

      server.createMBean(this.getClass().getName(), scheduleName);

      Any thoughts will be greatly appreciated.

      Thanks.