You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by "Shen, Minsheng (MinSheng)" <mi...@avaya.com> on 2007/10/22 03:15:18 UTC

Client can't receive the message due to read timed out

Hi All,
I am new to this mail list. 
I am developing a web service using CXF 2.0.2. Everything is tested and
works fine on the service side. I used wsdl2java to create a client.
When I invoke the client, I got "Interceptor has thrown exception,
unwinding now
org.apache.cxf.interceptor.Fault: Could not send Message."
 
I believe on the client side the default time out for reading message is
60 seconds and this error is caused by read time out. The following is
the stacktrace. Any help you can provide will be greatly appreciated!!
Thank you in advance!
 
-Minsheng
 
INFO: Interceptor has thrown exception, unwinding now

org.apache.cxf.interceptor.Fault: Could not send Message.

at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingI
nterceptor.handleMessage(MessageSenderInterceptor.java:64)

at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC
hain.java:207)

at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:254)

at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:205)

at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)

at
org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135)

at $Proxy28.getEquipmentLocationEntitlements(Unknown Source)

at
com.avaya.tsd.services.client.ISoldToAdministrationService_SoldToAdminis
trationServiceImplPort_Client.getEquipmentLocationEntitlements(ISoldToAd
ministrationService_SoldToAdministrationServiceImplPort_Client.java:82)

at
com.avaya.tsd.services.client.ISoldToAdministrationService_SoldToAdminis
trationServiceImplPort_Client.main(ISoldToAdministrationService_SoldToAd
ministrationServiceImplPort_Client.java:37)

Caused by: java.net.SocketTimeoutException: Read timed out

at java.net.SocketInputStream.socketRead0(Native Method)

at java.net.SocketInputStream.read(Unknown Source)

at java.io.BufferedInputStream.fill(Unknown Source)

at java.io.BufferedInputStream.read1(Unknown Source)

at java.io.BufferedInputStream.read(Unknown Source)

at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)

at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)

at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)

at java.net.HttpURLConnection.getResponseCode(Unknown Source)

at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResp
onse(HTTPConduit.java:1860)

at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTP
Conduit.java:1790)

at
org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:66)

at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:576)

at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingI
nterceptor.handleMessage(MessageSenderInterceptor.java:62)

... 8 more

Exception in thread "main" javax.xml.ws.soap.SOAPFaultException: Could
not send Message.

at
org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:175)

at $Proxy28.getEquipmentLocationEntitlements(Unknown Source)

at
com.avaya.tsd.services.client.ISoldToAdministrationService_SoldToAdminis
trationServiceImplPort_Client.getEquipmentLocationEntitlements(ISoldToAd
ministrationService_SoldToAdministrationServiceImplPort_Client.java:82)

at
com.avaya.tsd.services.client.ISoldToAdministrationService_SoldToAdminis
trationServiceImplPort_Client.main(ISoldToAdministrationService_SoldToAd
ministrationServiceImplPort_Client.java:37)

Caused by: org.apache.cxf.interceptor.Fault: Could not send Message.

at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingI
nterceptor.handleMessage(MessageSenderInterceptor.java:64)

at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC
hain.java:207)

at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:254)

at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:205)

at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)

at
org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135)

... 3 more

Caused by: java.net.SocketTimeoutException: Read timed out

at java.net.SocketInputStream.socketRead0(Native Method)

at java.net.SocketInputStream.read(Unknown Source)

at java.io.BufferedInputStream.fill(Unknown Source)

at java.io.BufferedInputStream.read1(Unknown Source)

at java.io.BufferedInputStream.read(Unknown Source)

at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)

at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)

at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)

at java.net.HttpURLConnection.getResponseCode(Unknown Source)

at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResp
onse(HTTPConduit.java:1860)

at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTP
Conduit.java:1790)

at
org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:66)

at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:576)

at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingI
nterceptor.handleMessage(MessageSenderInterceptor.java:62)

... 8 more


Re: Client can't receive the message due to read timed out

Posted by Willem2 <ni...@iona.com>.
Yes , You can specify which client's connection time out parameter that you
want to overwrite by using the Service's Port Name.
And please make sure you do not use the wild card in the
http-conf:conduit@name attribute.

You can refer this[1] for more information.
[1]http://cwiki.apache.org/CXF20DOC/client-http-transport.html

Willem.

MtnAlps wrote:
> 
> Hi Willem,
> If a client needs to connect to two web services, how to set the
> connection time out paramters for the client to connect to the two web
> services?
> 
> In the client configuration file, the attribute of name in the second
> <http-conf:conduit name=" ..."  > element overwrites the first one. Is it
> possible to configure a client connection time out parameters to multiple
> web services?
> Thanks
> -Minsheng
> 
> 
> 
> MtnAlps wrote:
>> 
>> Hi Willem,
>> Thank you so much for the info!!! The issue is fixed. We just migrated
>> from XFire 1.2.6 to CXF 2.0.2. A lot of issues we had with XFire 1.2.6
>> are gone.
>> Thanks!
>> -Miknsheng
>> 
>> 
>> Willem2 wrote:
>>> 
>>> Hi ,
>>> 
>>> FYI, you can find the how to set the timeout parameters here [1]
>>> [1] http://cwiki.apache.org/CXF20DOC/client-http-transport.html
>>> 
>>> 
>>> Willem.
>>> Glen Mazza wrote:
>>>> I'm not sure how to adjust the timeout parameters--someone else can
>>>> perhaps respond to that issue.
>>>>
>>>> But how long should it take your server to respond?  Can you greatly
>>>> simplify your server so it responds immediately (basically just mock it
>>>> out so it immediately returns something), to confirm that the 60-second
>>>> timeout is the real problem (as opposed to the client simply not being
>>>> able to access the server)?  
>>>>
>>>> The error you're getting:  "Caused by:
>>>> org.apache.cxf.interceptor.Fault:
>>>> Could not send Message."  normally occurs to me when the server is
>>>> inaccessible for some reason, it can't be reached at all--not just a
>>>> time-out issue.  Are you sure the URL in the WSDL (which I assume your
>>>> client is reading) is correct?  If you call
>>>> http://localhost:8080/mywarfilename/myservice?wsdl, for example, do you
>>>> see the WSDL file in the browser?
>>>>
>>>> HTH,
>>>> Glen
>>>>
>>>> Am Sonntag, den 21.10.2007, 19:15 -0600 schrieb Shen, Minsheng
>>>> (MinSheng):
>>>>   
>>>>> Hi All,
>>>>> I am new to this mail list. 
>>>>> I am developing a web service using CXF 2.0.2. Everything is tested
>>>>> and
>>>>> works fine on the service side. I used wsdl2java to create a client.
>>>>> When I invoke the client, I got "Interceptor has thrown exception,
>>>>> unwinding now
>>>>> org.apache.cxf.interceptor.Fault: Could not send Message."
>>>>>  
>>>>> I believe on the client side the default time out for reading message
>>>>> is
>>>>> 60 seconds and this error is caused by read time out. The following is
>>>>> the stacktrace. Any help you can provide will be greatly appreciated!!
>>>>> Thank you in advance!
>>>>>  
>>>>> -Minsheng
>>>>>  
>>>>> INFO: Interceptor has thrown exception, unwinding now
>>>>>
>>>>>     
>>>>
>>>>   
>>>>> org.apache.cxf.interceptor.Fault: Could not send Message.
>>>>>
>>>>>     
>>>>
>>>>
>>>>   
>>>>> Caused by: java.net.SocketTimeoutException: Read timed out
>>>>>
>>>>>     
>>>>
>>>>
>>>>
>>>>   
>>> 
>>> 
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Client-can%27t-receive-the-message-due-to-read-timed-out-tf4668231.html#a13449273
Sent from the cxf-user mailing list archive at Nabble.com.


Re: Client can't receive the message due to read timed out

Posted by MtnAlps <mi...@avaya.com>.
Hi Willem,
If a client needs to connect to two web services, how to set the connection
time out paramters for the client to connect to the two web services?

In the client configuration file, the attribute of name in the second
<http-conf:conduit name=" ..."  > element overwrites the first one. Is it
possible to configure a client connection time out parameters to multiple
web services?
Thanks
-Minsheng



MtnAlps wrote:
> 
> Hi Willem,
> Thank you so much for the info!!! The issue is fixed. We just migrated
> from XFire 1.2.6 to CXF 2.0.2. A lot of issues we had with XFire 1.2.6 are
> gone.
> Thanks!
> -Miknsheng
> 
> 
> Willem2 wrote:
>> 
>> Hi ,
>> 
>> FYI, you can find the how to set the timeout parameters here [1]
>> [1] http://cwiki.apache.org/CXF20DOC/client-http-transport.html
>> 
>> 
>> Willem.
>> Glen Mazza wrote:
>>> I'm not sure how to adjust the timeout parameters--someone else can
>>> perhaps respond to that issue.
>>>
>>> But how long should it take your server to respond?  Can you greatly
>>> simplify your server so it responds immediately (basically just mock it
>>> out so it immediately returns something), to confirm that the 60-second
>>> timeout is the real problem (as opposed to the client simply not being
>>> able to access the server)?  
>>>
>>> The error you're getting:  "Caused by: org.apache.cxf.interceptor.Fault:
>>> Could not send Message."  normally occurs to me when the server is
>>> inaccessible for some reason, it can't be reached at all--not just a
>>> time-out issue.  Are you sure the URL in the WSDL (which I assume your
>>> client is reading) is correct?  If you call
>>> http://localhost:8080/mywarfilename/myservice?wsdl, for example, do you
>>> see the WSDL file in the browser?
>>>
>>> HTH,
>>> Glen
>>>
>>> Am Sonntag, den 21.10.2007, 19:15 -0600 schrieb Shen, Minsheng
>>> (MinSheng):
>>>   
>>>> Hi All,
>>>> I am new to this mail list. 
>>>> I am developing a web service using CXF 2.0.2. Everything is tested
>>>> and
>>>> works fine on the service side. I used wsdl2java to create a client.
>>>> When I invoke the client, I got "Interceptor has thrown exception,
>>>> unwinding now
>>>> org.apache.cxf.interceptor.Fault: Could not send Message."
>>>>  
>>>> I believe on the client side the default time out for reading message
>>>> is
>>>> 60 seconds and this error is caused by read time out. The following is
>>>> the stacktrace. Any help you can provide will be greatly appreciated!!
>>>> Thank you in advance!
>>>>  
>>>> -Minsheng
>>>>  
>>>> INFO: Interceptor has thrown exception, unwinding now
>>>>
>>>>     
>>>
>>>   
>>>> org.apache.cxf.interceptor.Fault: Could not send Message.
>>>>
>>>>     
>>>
>>>
>>>   
>>>> Caused by: java.net.SocketTimeoutException: Read timed out
>>>>
>>>>     
>>>
>>>
>>>
>>>   
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Client-can%27t-receive-the-message-due-to-read-timed-out-tf4668231.html#a13437670
Sent from the cxf-user mailing list archive at Nabble.com.


Re: Client can't receive the message due to read timed out

Posted by MtnAlps <mi...@avaya.com>.
Hi Willem,
Thank you so much for the info!!! The issue is fixed. We just migrated from
XFire 1.2.6 to CXF 2.0.2. A lot of issues we had with XFire 1.2.6 are gone.
Thanks!
-Miknsheng


Willem2 wrote:
> 
> Hi ,
> 
> FYI, you can find the how to set the timeout parameters here [1]
> [1] http://cwiki.apache.org/CXF20DOC/client-http-transport.html
> 
> 
> Willem.
> Glen Mazza wrote:
>> I'm not sure how to adjust the timeout parameters--someone else can
>> perhaps respond to that issue.
>>
>> But how long should it take your server to respond?  Can you greatly
>> simplify your server so it responds immediately (basically just mock it
>> out so it immediately returns something), to confirm that the 60-second
>> timeout is the real problem (as opposed to the client simply not being
>> able to access the server)?  
>>
>> The error you're getting:  "Caused by: org.apache.cxf.interceptor.Fault:
>> Could not send Message."  normally occurs to me when the server is
>> inaccessible for some reason, it can't be reached at all--not just a
>> time-out issue.  Are you sure the URL in the WSDL (which I assume your
>> client is reading) is correct?  If you call
>> http://localhost:8080/mywarfilename/myservice?wsdl, for example, do you
>> see the WSDL file in the browser?
>>
>> HTH,
>> Glen
>>
>> Am Sonntag, den 21.10.2007, 19:15 -0600 schrieb Shen, Minsheng
>> (MinSheng):
>>   
>>> Hi All,
>>> I am new to this mail list. 
>>> I am developing a web service using CXF 2.0.2. Everything is tested
>>> and
>>> works fine on the service side. I used wsdl2java to create a client.
>>> When I invoke the client, I got "Interceptor has thrown exception,
>>> unwinding now
>>> org.apache.cxf.interceptor.Fault: Could not send Message."
>>>  
>>> I believe on the client side the default time out for reading message
>>> is
>>> 60 seconds and this error is caused by read time out. The following is
>>> the stacktrace. Any help you can provide will be greatly appreciated!!
>>> Thank you in advance!
>>>  
>>> -Minsheng
>>>  
>>> INFO: Interceptor has thrown exception, unwinding now
>>>
>>>     
>>
>>   
>>> org.apache.cxf.interceptor.Fault: Could not send Message.
>>>
>>>     
>>
>>
>>   
>>> Caused by: java.net.SocketTimeoutException: Read timed out
>>>
>>>     
>>
>>
>>
>>   
> 
> 

-- 
View this message in context: http://www.nabble.com/Client-can%27t-receive-the-message-due-to-read-timed-out-tf4668231.html#a13379530
Sent from the cxf-user mailing list archive at Nabble.com.


Re: Client can't receive the message due to read timed out

Posted by Willem Jiang <ni...@iona.com>.
Hi ,

FYI, you can find the how to set the timeout parameters here [1]
[1] http://cwiki.apache.org/CXF20DOC/client-http-transport.html


Willem.
Glen Mazza wrote:
> I'm not sure how to adjust the timeout parameters--someone else can
> perhaps respond to that issue.
>
> But how long should it take your server to respond?  Can you greatly
> simplify your server so it responds immediately (basically just mock it
> out so it immediately returns something), to confirm that the 60-second
> timeout is the real problem (as opposed to the client simply not being
> able to access the server)?  
>
> The error you're getting:  "Caused by: org.apache.cxf.interceptor.Fault:
> Could not send Message."  normally occurs to me when the server is
> inaccessible for some reason, it can't be reached at all--not just a
> time-out issue.  Are you sure the URL in the WSDL (which I assume your
> client is reading) is correct?  If you call
> http://localhost:8080/mywarfilename/myservice?wsdl, for example, do you
> see the WSDL file in the browser?
>
> HTH,
> Glen
>
> Am Sonntag, den 21.10.2007, 19:15 -0600 schrieb Shen, Minsheng
> (MinSheng):
>   
>> Hi All,
>> I am new to this mail list. 
>> I am developing a web service using CXF 2.0.2. Everything is tested
>> and
>> works fine on the service side. I used wsdl2java to create a client.
>> When I invoke the client, I got "Interceptor has thrown exception,
>> unwinding now
>> org.apache.cxf.interceptor.Fault: Could not send Message."
>>  
>> I believe on the client side the default time out for reading message
>> is
>> 60 seconds and this error is caused by read time out. The following is
>> the stacktrace. Any help you can provide will be greatly appreciated!!
>> Thank you in advance!
>>  
>> -Minsheng
>>  
>> INFO: Interceptor has thrown exception, unwinding now
>>
>>     
>
>   
>> org.apache.cxf.interceptor.Fault: Could not send Message.
>>
>>     
>
>
>   
>> Caused by: java.net.SocketTimeoutException: Read timed out
>>
>>     
>
>
>
>   

Re: Client can't receive the message due to read timed out

Posted by Glen Mazza <gl...@verizon.net>.
I'm not sure how to adjust the timeout parameters--someone else can
perhaps respond to that issue.

But how long should it take your server to respond?  Can you greatly
simplify your server so it responds immediately (basically just mock it
out so it immediately returns something), to confirm that the 60-second
timeout is the real problem (as opposed to the client simply not being
able to access the server)?  

The error you're getting:  "Caused by: org.apache.cxf.interceptor.Fault:
Could not send Message."  normally occurs to me when the server is
inaccessible for some reason, it can't be reached at all--not just a
time-out issue.  Are you sure the URL in the WSDL (which I assume your
client is reading) is correct?  If you call
http://localhost:8080/mywarfilename/myservice?wsdl, for example, do you
see the WSDL file in the browser?

HTH,
Glen

Am Sonntag, den 21.10.2007, 19:15 -0600 schrieb Shen, Minsheng
(MinSheng):
> Hi All,
> I am new to this mail list. 
> I am developing a web service using CXF 2.0.2. Everything is tested
> and
> works fine on the service side. I used wsdl2java to create a client.
> When I invoke the client, I got "Interceptor has thrown exception,
> unwinding now
> org.apache.cxf.interceptor.Fault: Could not send Message."
>  
> I believe on the client side the default time out for reading message
> is
> 60 seconds and this error is caused by read time out. The following is
> the stacktrace. Any help you can provide will be greatly appreciated!!
> Thank you in advance!
>  
> -Minsheng
>  
> INFO: Interceptor has thrown exception, unwinding now
> 

> org.apache.cxf.interceptor.Fault: Could not send Message.
> 


> Caused by: java.net.SocketTimeoutException: Read timed out
>