0 Replies Latest reply on Feb 13, 2004 11:00 AM by dare

    Setting a URLConnection Timeout?

    dare

      I make a number of HttpURLConnections from my
      Servlets to outside sources on the Internet.

      When one of those remote sites hang, the URLConnection
      hangs, and causes the Servlet Thread to hang. Since this
      is a high volume site, when that remote site hangs, my
      JBoss server will eventually use up all it's available servlet
      connections, while it is waiting for the URLConnections to
      return...

      Is there a way to implement a timeout on the URLConnection?

      If not, will setting the default timeout on a user's session
      work for a stateless session inside JBoss/Jetty?

      Thanks!

      Rob.