setTimeout

"Ching, Vivian M, ALABS" <[email protected]> Wed, 20 Oct 2004 17:39:13 -0500
Newsgroups gmane.text.xml.soap.devel
Message-ID <456FD0E7B215B24ABBAD711614E4A7A20A0BB5F9@OCCLUST03EVS1.ugd.att.com>
Hi-
 
I am trying the set the timeout value for soap request,
using the code below.  The send/receive is still waiting
40 seconds before I get the java.net.ConnectException: 
Connection timed out.
Is this timeout for the recieve only and I am blocked on
the send?  If so, how do I set the connection timeout?
Any help will be greatly appreciated!
Thanks in advance,
 
 
  Envelope env = null;         
  Message msg = new Message();
  SOAPHTTPConnection st = new SOAPHTTPConnection();
  msg.setSOAPTransport(st);
  st.setTimeout(2000);
 
  try {
   msg.send(new URL(sURL), soapAction, requestEnvelope);
   env = msg.receiveEnvelope();
  } 
   
 
Vivian Ching
AT&T
MT A2-2E04
200 S Laurel Avenue
Middletown, NJ 07748
732.420.2452