Read Timed Out error in CXF

Solution Unverified - Updated -

Issue

  • We are seeing this issue interim, after some time it works. In our log appears the error with the module org.apache.cxf and timed out connection:
javax.xml.ws.WebServiceException: Could not send Message.
                at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:146)
Caused by: java.net.SocketTimeoutException: SocketTimeoutException invoking https://www.example.com/app: Read timed out
                at sun.reflect.GeneratedConstructorAccessor165.newInstance(Unknown Source)
                at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
                at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
                at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.mapException(HTTPConduit.java:1347)
                at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1331)
                at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56)
                at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:632)
                at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62)
                at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:272)
                at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:570)
                at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:479)
                at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:382)
                at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:335)
                at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:96)
                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(SocketInputStream.java:129)
                at com.sun.net.ssl.internal.ssl.InputRecord.readFully(InputRecord.java:293)
                at com.sun.net.ssl.internal.ssl.InputRecord.read(InputRecord.java:331)
                at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:789)
                at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:746)
                at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75)
                at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
                at java.io.BufferedInputStream.read1(BufferedInputStream.java:258)
                at java.io.BufferedInputStream.read(BufferedInputStream.java:317)
                at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:687)
                at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:632)
                at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:766)
                at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:632)
                at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1072)
                at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:373)
                at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(HttpsURLConnectionImpl.java:318)
                at org.apache.cxf.transport.http.URLConnectionHTTPConduit$URLConnectionWrappedOutputStream.getResponseCode(URLConnectionHTTPConduit.java:266)
                at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:1543)
                at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1513)
                at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1318)
                ... 13 more

Environment

  • JBoss Enterprise Application Platform (EAP) 6.x
  • JBoss Enterprise Application Platform (EAP) 5.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In