3 Replies Latest reply on Oct 26, 2005 9:54 AM by ogj

    Timeout for RMI Communication??

    bridenour

      Hi All:

      I've checked hi and lo and can't find a suitable answer for this question. We have a distributed system with two jboss clusters communicating with each other via RMI. We are using HA-JNDI as well.

      Sometimes, cluster 1 makes an RMI call into cluster 2, and cluster 2 takes a long time/forever to respond. In this situation, we would like the RMI call in cluster 1 to timeout, independently of cluster 2.

      Is there anyway to configure a jboss client to timeout its RMI call if the execution in the remote server has not completed? The RMI configs on the JVM do not seem to be appropriate for this situation.

      Thanks,
      Brandon

        • 1. Re: Timeout for RMI Communication??
          bridenour

          I would not have thought this would be such an uncommon and/or complicated problem. I don't really see how jndi/rmi calls could be practical at the enterprise level without the ability to set a timeout.

          • 2. Re: Timeout for RMI Communication??
            andreas_knecht

            Agreed! I've got pretty much exactly the same problem and I thought as well that this would be a fairly common problem. Apparently not so. I tried to approach it from a different side (see my post about transaction timeout behaviour: [URL]http://www.jboss.org/index.html?module=bb&op=viewtopic&t=61726[/URL]), to see if there's anything we can do in JBoss when the transaction times out.

            Jboss currently only marks the transaction as rollback. It would be much more usefull if it would actually perform the rollback and as a result release all the resources and terminate the RMI call.

            So far I haven't found anything useful, but if I do I'll certainly share it...

            • 3. Re: Timeout for RMI Communication??
              ogj

              I thought this would be easy, but was disappointed when I searched the forum. Is there no solution for this? What do other people do? Use a different invoker? Write their own invokers?