1 Reply Latest reply on Jul 27, 2004 9:35 AM by Scott Stark

    javax.naming.CommunicationException: for multiple clients

    Dhanan Naoriya Newbie

      I am having an application which will create 50 clients(threads) . When these threads try to lookup the ejb home simultaneously some of them (around 30 )got the ejb object while others could not giving the exception :

      javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out]
      at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1086)
      at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1163)
      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:485)
      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:478)
      at javax.naming.InitialContext.lookup(Unknown Source)
      at test.session.NewClient.callEJBClient(NewClient.java:86)
      at test.session.NewClient.doThis(NewClient.java:42)
      at test.session.NewClient.run(NewClient.java:33)
      Caused by: java.net.SocketTimeoutException: Receive timed out
      at java.net.PlainDatagramSocketImpl.receive(Native Method)
      at java.net.DatagramSocket.receive(Unknown Source)
      at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1064)
      The result is ... :: Time taken: 6250
      ... 7 more
      javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out]
      at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1086)
      at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1163)
      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:485)
      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:478)
      at javax.naming.InitialContext.lookup(Unknown Source)


      I dint change any default setting of the server JBOSS.

      Why some of the threads ar not able to get the object.
      Any suggestion.........