8 Replies Latest reply on Jun 21, 2006 12:44 PM by balajiv

    I seem to be having a simular problem

    rdanner

      I know j2ee servers run RMI/IIOP but my understandding is that it is compatiple with RMI/JRMP.

      I deployed an application in to JBoss today that was compiled with the standard RMIC and when it attempts to bind to the RMI port running on jboss (1098) I get the following error.

      07:50:00,234 ERROR [RmiJcrClientRepository] binding failure [java.rmi.ConnectIOException: non-JRMP server at remote endpoint]
      07:50:17,019 ERROR [RemoteContentRepositoryServicesFactory] binding failure [java.rmi.NoSuchObjectException: no such object in table]

      What is the deal with RMI/IIOP? Do I need special stubs/Skeletons? I noticed i get similar results even if I try to bind from an app in jboss to the basic rmiregistry running outside of jboss.

        • 1. Re: I seem to be having a simular problem
          rdanner

           

          "rdanner" wrote:
          I know j2ee servers run RMI/IIOP but my understandding is that it is compatiple with RMI/JRMP.

          I deployed an application in to JBoss today that was compiled with the standard RMIC and when it attempts to bind to the RMI port running on jboss (1098) I get the following error.

          07:50:00,234 ERROR [RmiJcrClientRepository] binding failure [java.rmi.ConnectIOException: non-JRMP server at remote endpoint]
          07:50:17,019 ERROR [RemoteContentRepositoryServicesFactory] binding failure [java.rmi.NoSuchObjectException: no such object in table]

          What is the deal with RMI/IIOP? Do I need special stubs/Skeletons? I noticed i get similar results even if I try to bind from an app in jboss to the basic rmiregistry running outside of jboss.


          Currently I am looking at recompiling (rmic) with -iiop


          RMI-IIOP utilizes the Java CORBA Object Request Broker (ORB) and IIOP, so you can write all of your code in the Java programming language, and use the rmic compiler to generate the code necessary for connecting your applications via the Internet InterORB Protocol (IIOP) to others written in any CORBA-compliant language. To work with CORBA applications in other languages, IDL can be generated from Java programming language interfaces using the rmic compiler with the -idl option. To generate IIOP stubs and tie classes, use the rmic compiler with the -iiop option. For more information on using rmic, link to rmic - The Java RMI Compiler.
          When should I use RMI-IIOP?

          RMI-IIOP is for developers who program in the Java programming language and want to program to the RMI interfaces, but use IIOP as the underlying transport. RMI-IIOP provides interoperability with other CORBA objects implemented in various languages - but only if all the remote interfaces are originally defined as Java RMI interfaces. It is of particular interest to programmers using Enterprise JavaBeansTM (EJBTM), since the remote object model for EJB components is based on the RMI API.



          • 2. Re: I seem to be having a simular problem
            rdanner

             

            "rdanner" wrote:
            "rdanner" wrote:
            I know j2ee servers run RMI/IIOP but my understandding is that it is compatiple with RMI/JRMP.

            I deployed an application in to JBoss today that was compiled with the standard RMIC and when it attempts to bind to the RMI port running on jboss (1098) I get the following error.

            07:50:00,234 ERROR [RmiJcrClientRepository] binding failure [java.rmi.ConnectIOException: non-JRMP server at remote endpoint]
            07:50:17,019 ERROR [RemoteContentRepositoryServicesFactory] binding failure [java.rmi.NoSuchObjectException: no such object in table]

            What is the deal with RMI/IIOP? Do I need special stubs/Skeletons? I noticed i get similar results even if I try to bind from an app in jboss to the basic rmiregistry running outside of jboss.


            Currently I am looking at recompiling (rmic) with -iiop


            RMI-IIOP utilizes the Java CORBA Object Request Broker (ORB) and IIOP, so you can write all of your code in the Java programming language, and use the rmic compiler to generate the code necessary for connecting your applications via the Internet InterORB Protocol (IIOP) to others written in any CORBA-compliant language. To work with CORBA applications in other languages, IDL can be generated from Java programming language interfaces using the rmic compiler with the -idl option. To generate IIOP stubs and tie classes, use the rmic compiler with the -iiop option. For more information on using rmic, link to rmic - The Java RMI Compiler.
            When should I use RMI-IIOP?

            RMI-IIOP is for developers who program in the Java programming language and want to program to the RMI interfaces, but use IIOP as the underlying transport. RMI-IIOP provides interoperability with other CORBA objects implemented in various languages - but only if all the remote interfaces are originally defined as Java RMI interfaces. It is of particular interest to programmers using Enterprise JavaBeansTM (EJBTM), since the remote object model for EJB components is based on the RMI API.



            Well I compiled with the -iiop and now I get a different error

            java.net.ConnectException: Connection refused: connect

            I would have thought I would have got this prior to getting the non-JRMP error. My hunch is that this is a policy issue? anyone know?


            • 3. Re: I seem to be having a simular problem
              rdanner

              Well... I just looked at my server policy and it seems to indicate that it's not a policy issue :)

              grant {
              // Allow everything for now
              permission java.security.AllPermission;
              };

              • 4. Re: I seem to be having a simular problem
                rdanner

                Ugh :)

                on Naming.bing(x,x) I get:

                error marshalling arguments
                Software caused connection abort: socket write error

                • 5. Re: I seem to be having a simular problem
                  rdanner

                   

                  "rdanner" wrote:
                  Ugh :)

                  on Naming.bing(x,x) I get:

                  error marshalling arguments
                  Software caused connection abort: socket write error


                  Ok I am basically out of ideas, I am running the JBOSS server in default mode which seems to be running RMI/IIOP.

                  I have changed by interfaces to PortableRemoteObject, compiled with rmic -iiop and switched to

                  InitialContext vNamingContext = new InitialContext();
                  vRemoteRepository = vRemoteAdapterFactory.getRemoteRepository(vInstActualRepository);
                  vNamingContext.bind(vInstRemoteRepositoryMoniker, vRemoteRepository);


                  In the end I get a CommunicationException with a root exception of
                  org.apache.jackrabbit.rmi.server.ServerRepository


                  ServerRepository extends a class that extends PortableRemoteObject
                  but ServerRepository has private reference to objects which are not serializable such as Repository (the actual repository). Repository is not serializable.

                  This all worked under RMI/JRMP. I am not a RMI wizard and I am a little tired so I have kinda shut down at this point but i think i need a hint here or some leads



                  • 6. Re: I seem to be having a simular problem
                    starksm64

                    jboss does not use RMI/IIOP by default. It also does not provide an RMI registry. The 1099 port is a socket based JNDI implementation that supports access via an RMI/JRMP protocol by default. See the RMI Registry Service Provider section of the jdk javadoc for ways to bind into a non-RMI registry.

                    • 7. Re: I seem to be having a simular problem
                      dsecondymail

                       

                      "scott.stark@jboss.org" wrote:
                      jboss does not use RMI/IIOP by default. It also does not provide an RMI registry. The 1099 port is a socket based JNDI implementation that supports access via an RMI/JRMP protocol by default. See the RMI Registry Service Provider section of the jdk javadoc for ways to bind into a non-RMI registry.


                      I hava the same problem, on our project, we want to use jboss as ejb container , but we also have some rmi server runs on different machines independently, I don't want to use rmiregistry for rmi or tnameserv for rmi-iiop, I want to let the rmi or rmi-iiop server rebind it's implementation into jboss.
                      but as you have said, does it meaning that it's impossible for us to do this?

                      another question, if I use rmiregistry or tnameserv instead, and I will call rmi server in stateless session bean, I think this must can be finished successfully in jboss, is it right?

                      thanks inadvance

                      • 8. Re: I seem to be having a simular problem
                        balajiv

                        Hi,
                        Did you guys get the answer for this thread?.
                        Basically, we were running RMI outside JBoss and we were using the JBoss for some webservice functionality. To make our life simpler, we want to run everything in one place and so we decided to run our rmi within JBoss server (rmiport 1098). But I am not able to add the remote object to the registry and it is throwing java.rmi.NoSuchObjectException: no such object in table.
                        But when I run our rmi server outside JBoss with the regular rmiregistry.exe, it works fine and we were able to add the services to registry. I even added
                        -Djava.rmi.server.hostname=[hostname]
                        -Djava.security.policy=[dir]\policy.txt in the startup run.bat script.
                        I really don't know how to proceed with this. Please help me out!!!