1 Reply Latest reply on May 15, 2007 5:19 AM by faisalhelpline

    Migration issues from previous versions(JBOSS 3.2.x) to JBOS

    faisalhelpline Newbie

      I have made an application which is clustered enabled. but i am facing few issues while porting it onto jBOSS4.0.5, its perfectly running in JBOSS-3.2.6

      1-HARMIProxyCallBack interface not found, in JBOSS-4.0.5 what is the alternate of it.
      i had RMIListnerMBean which is extends ServiceMBeanSupport and implements HARMIProxyCallback

      and in the start Service Method i was doing something like

      String fullPartitionName = "/HAPartition/DefaultPartition";
      context = new InitialContext();
      partition = (HAPartition) context.lookup(fullPartitionName);
      // Create a clustered Proxy/stub
      msghandler = new MyMessageHandler();//my own class extending the Listner Class
      myHARMIServer = new HARMIServerImpl(partition, "RmiMessageServer", Listener.class,
      msghandler, 0, null, null, null, this);
      stub = myHARMIServer.createHAStub(new RoundRobin());
      rebind();

      should i port this code other way..? to make it compatible with JBOSS4.0.5

      2-getting error while invoking on

      context = new InitialContext();
      adaptor = (RMIAdaptor) context.lookup("jmx/rmi/RMIAdaptor");
      ObjectName objName = new ObjectName("txt:config=Core");
      Object obj = adaptor.invoke(objName, "getCoreDBSource",null, null);
      this piece of code is working fine in 3.2.6 version.

      i read somewhere that in new versions we should use MBeanServerConnection instead of RMIAdaptor i used it but still getting exception:
      javax.management.ReflectionException
      at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInv

      is there any need... to extend MBean from certain classes or implement any interface?
      my MBean is very simple..
      extending HAServiceMBeanSupport and implementing NotificationListener.

        • 1. Re: Migration issues from previous versions(JBOSS 3.2.x) to
          faisalhelpline Newbie

           

          "faisalhelpline" wrote:
          I have made an application which is clustered enabled. but i am facing few issues while porting it onto jBOSS4.0.5, its perfectly running in JBOSS-3.2.6

          1-HARMIProxyCallBack interface not found, in JBOSS-4.0.5 what is the alternate of it.
          i had RMIListnerMBean which is extends ServiceMBeanSupport and implements HARMIProxyCallback

          and in the start Service Method i was doing something like

          String fullPartitionName = "/HAPartition/DefaultPartition";
          context = new InitialContext();
          partition = (HAPartition) context.lookup(fullPartitionName);
          // Create a clustered Proxy/stub
          msghandler = new MyMessageHandler();//my own class extending the Listner Class
          myHARMIServer = new HARMIServerImpl(partition, "RmiMessageServer", Listener.class,
          msghandler, 0, null, null, null, this);
          stub = myHARMIServer.createHAStub(new RoundRobin());
          rebind();

          should i port this code other way..? to make it compatible with JBOSS4.0.5

          2-getting error while invoking on

          context = new InitialContext();
          adaptor = (RMIAdaptor) context.lookup("jmx/rmi/RMIAdaptor");
          ObjectName objName = new ObjectName("txt:config=Core");
          Object obj = adaptor.invoke(objName, "getCoreDBSource",null, null);
          this piece of code is working fine in 3.2.6 version.

          i read somewhere that in new versions we should use MBeanServerConnection instead of RMIAdaptor i used it but still getting exception:
          javax.management.ReflectionException
          at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInv

          is there any need... to extend MBean from certain classes or implement any interface?
          my MBean is very simple..
          extending HAServiceMBeanSupport and implementing NotificationListener.