I am trying to connect to SharePoint 2013 using Apache Chemistry CMIS Web services binding. I have given valid WSDL url.
Sometimes I am able to make a valid connection and perform CMIS operations. But sometimes I get the following exception trace :
org.apache.chemistry.opencmis.commons.exceptions.CmisRuntimeException: Error: The server sent HTTP status code 401: Unauthorized at org.apache.chemistry.opencmis.client.bindings.spi.webservices.ObjectServiceImpl.createDocument(ObjectServiceImpl.java:92) at org.apache.chemistry.opencmis.client.runtime.SessionImpl.createDocument(SessionImpl.java:751) at org.apache.chemistry.opencmis.client.runtime.SessionImpl.createDocument(SessionImpl.java:882) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.codehaus.groovy.runtime.callsite.PojoMetaMethodSite$PojoCachedMethodSite.invoke(PojoMetaMethodSite.java:189) at org.codehaus.groovy.runtime.callsite.PojoMetaMethodSite.call(PojoMetaMethodSite.java:53) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:128) .................................
What is the reason for this mixed behaviour. And how do I get rid of this exception