4 Replies Latest reply on Jan 19, 2005 4:08 AM by Scott Stark

    jdk1.4 + jboss4.0.1, RMI not working

    Emily Newbie

      I am in the process of upgrading from 4.0.0 to 4.0.1. I'm using jdk1.4.2_03 and it looks like in jboss4.0.1, RMI calls are failing (Receive timed out). I read that the RMI code was upgraded in jboss4.0.1 to work with java 1.5. Does this mean it is not backwards compatible?

        • 1. Re: jdk1.4 + jboss4.0.1, RMI not working
          Emily Newbie

          I just tried upgrading to jdk1.5, and I am still seeing the RMI problem in jboss4.0.1, so there must be something that changed about how to use RMI with jboss4.0.1. I don't see anything yet in the documentation. Is there anything obvious someone could help me with?

          14:19:30,187 INFO [STDOUT 140] javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: R
          eceive timed out]
          14:19:30,187 INFO [STDOUT 140] at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1159)
          14:19:30,187 INFO [STDOUT 140] at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1239)
          14:19:30,187 INFO [STDOUT 140] at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:527)
          14:19:30,197 INFO [STDOUT 140] at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:520)
          14:19:30,197 INFO [STDOUT 140] at javax.naming.InitialContext.lookup(InitialContext.java:351)

          • 2. Re: jdk1.4 + jboss4.0.1, RMI not working
            Emily Newbie

            Here's what I'm trying to do

             Properties props = new Properties();
             String namingProvider ="jnp://" + hostname + ":" + port;
             props.put("java.naming.provider.url", namingProvider);
             InitialContext initialContext = new InitialContext(props);
             Object ref = initialContext.lookup("jmx/rmi/RMIAdaptor");
             if( log.isDebugEnabled() )
             log.debug( "looking up RMIAdaptor on " + hostname );
             return (RMIAdaptor) ref;

            This WAS working in jboss4.0.0...please help!

            • 3. Re: jdk1.4 + jboss4.0.1, RMI not working
              Emily Newbie

              ah HA. Looks like it's only failing for "localhost" lookups. If I catch localhost lookups and replace them with their actual names with InetAddress.getLocalHost().getHostName() everything works. This seems like a bug?

              • 4. Re: jdk1.4 + jboss4.0.1, RMI not working
                Scott Stark Master

                What does netstat -an | grep 1099 show for 4.0.0 and 4.0.1? It seems that its jndi is not bound to the localhost or all interfaces.