cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t-hunter <ravindra....@gmail.com>
Subject Re: timeout not working for me
Date Tue, 14 Oct 2008 14:19:25 GMT



t-hunter wrote:
> 
> Hi, 
> 
> I have problem with timeout problem when calling CXF service using JAX-WS.
> 
> here is my code,
> 
> 
> 
>                         QName svcQName = new QName(getServiceNS(),
> getServiceName());
> 
> 			QName portQName = new QName(getPortNS(), getPort());
> 
> 			Service service = Service.create(svcQName);
> 
> 			service.addPort(portQName,
> SOAPBinding.SOAP11HTTP_BINDING,getEndpoint());
> 
>                         Dispatch<SOAPMessage> dispatchSOAP=
> service.createDispatch(portQName, SOAPMessage.class,
> Service.Mode.MESSAGE);
> 
> 			dispatchSOAP.getRequestContext().put("com.sun.xml.ws.connect.timeout",
> new Integer(10*1000));
> 
> 			dispatchSOAP.getRequestContext().put("com.sun.xml.ws.request.timeout",
> new Integer(10*1000));
> 
>                         SOAPMessage response =
> dispatchSOAP.invoke(message);
> 
> 
> I want generate timeout exception after 10 sec. But I'm getting response
> in 20 sec.
> 
> 
> Can any please assist me how to raise timeout exception after specified
> time.
> I'm using apache-cxf-2.1.2 distribution jar libray.
> 
> 
> Thanks in advance.
> 

-- 
View this message in context: http://www.nabble.com/timeout-not-working-for-me-tp19974436p19974490.html
Sent from the cxf-user mailing list archive at Nabble.com.


Mime
View raw message