Hi All,
I am getting the 401 Unauthorized while invoking the webservice, it works
for some time but after around 2 hours the CXF API starts throwing
exception, I was using my other JAxWS API which does not show this error.
All the subsequent invocation throws this exception until I restart my
Application service. Please help me what could be the problem.
Interceptor for {XXXXXX#{http://cxf.apache.org/jaxws/dispatch}Invoke has
thrown exception, unwinding now
org.apache.cxf.interceptor.Fault: Could not send Message.
at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:64)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:243)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:516)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:313)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:265)
at org.apache.cxf.endpoint.ClientImpl.invokeWrapped(ClientImpl.java:300)
at org.apache.cxf.jaxws.DispatchImpl.invoke(DispatchImpl.java:332)
at org.apache.cxf.jaxws.DispatchImpl.invoke(DispatchImpl.java:218)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.io.IOException: HTTP response '401: Unauthorized' invoking
XXXXXX with NO authorization username configured in conduit
{XXXXXX}YYY.http-conduit
at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:2167)
at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:66)
at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:695)
at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62)
... 22 more
Caused by: java.net.HttpRetryException: cannot retry due to server
authentication, in streaming mode
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)
at java.net.HttpURLConnection.getResponseCode(Unknown Source)
at
sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(Unknown
Source)
at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:2305)
at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:2274)
at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:2119)
... 25 more
javax.xml.ws.WebServiceException: Could not send Message.
at org.apache.cxf.jaxws.DispatchImpl.mapException(DispatchImpl.java:244)
at org.apache.cxf.jaxws.DispatchImpl.invoke(DispatchImpl.java:339)
at org.apache.cxf.jaxws.DispatchImpl.invoke(DispatchImpl.java:218)
at
com.realops.adapter.ws.soap.dispatch.MessageClient.invoke(MessageClient.java:393)
at
com.realops.adapter.ws.soap.SoapRpcActorAdapter.performAction(SoapRpcActorAdapter.java:1166)
at sun.reflect.GeneratedMethodAccessor147.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at
com.realops.common.util.proxy.ContextClassLoaderDecoratorFactory$IsolatedInvocationHandler.doInvoke(ContextClassLoaderDecoratorFactory.java:79)
at
com.realops.common.util.proxy.AbstractInvocationHandler.invoke(AbstractInvocationHandler.java:89)
at com.sun.proxy.$Proxy165.performAction(Unknown Source)
at
com.realops.foundation.adapterframework.AdapterManager.performAction(AdapterManager.java:2561)
at
com.realops.foundation.adapterframework.DefaultAdapterProxy.performActionImpl(DefaultAdapterProxy.java:403)
at
com.realops.foundation.adapterframework.DefaultAdapterProxy.access$000(DefaultAdapterProxy.java:69)
at
com.realops.foundation.adapterframework.DefaultAdapterProxy$1.run(DefaultAdapterProxy.java:427)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.io.IOException: HTTP response '401: Unauthorized' invoking
https://XXXXX with NO authorization username configured in conduit
{XXXXXX}YYYY.http-conduit
at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:2167)
at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:66)
at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:695)
at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:243)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:516)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:313)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:265)
at org.apache.cxf.endpoint.ClientImpl.invokeWrapped(ClientImpl.java:300)
at org.apache.cxf.jaxws.DispatchImpl.invoke(DispatchImpl.java:332)
... 16 more
Caused by: java.net.HttpRetryException: cannot retry due to server
authentication, in streaming mode
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)
at java.net.HttpURLConnection.getResponseCode(Unknown Source)
at
sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(Unknown
Source)
at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:2305)
at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:2274)
at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:2119)
... 25 more
--Deepak