chemistry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nicolae Marasoiu <>
Subject RE: response code -1 (request not sent?)
Date Tue, 21 Oct 2014 08:58:48 GMT

I reproduced it in a different scenario. Right now, it is checking a folder existence:

Here is the exception trace:
..Cased by: (so the below is the root cause, no more Caused by. Also debugging, I saw code=-1,
so my feeling is that it is not the result of a server response. Pls check debug I made, below)
        at org.apache.chemistry.opencmis.client.bindings.spi.atompub.AbstractAtomPubService.convertStatusCode(
        at org.apache.chemistry.opencmis.client.bindings.spi.atompub.AbstractAtomPubService.getObjectInternal(
        at org.apache.chemistry.opencmis.client.bindings.spi.atompub.ObjectServiceImpl.getObjectByPath(
        at org.apache.chemistry.opencmis.client.runtime.SessionImpl.getObjectByPath(
        at org.apache.chemistry.opencmis.client.runtime.SessionImpl.getObjectByPath(
        at sun.reflect.GeneratedMethodAccessor49.invoke(Unknown Source) [:1.7.0_51]
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(
        at java.lang.reflect.Method.invoke( [rt.jar:1.7.0_51]
        at org.jboss.weld.bean.proxy.AbstractBeanInstance.invoke(
[weld-core-impl-2.1.2.Final.jar:2014-01-09 09:23]
        at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(
[weld-core-impl-2.1.2.Final.jar:2014-01-09 09:23]
        at org.jboss.weld.proxies.Serializable$Session$2053138592$Proxy$_$$_WeldClientProxy.getObjectByPath(Unknown
Source) [weld-core-impl-2.1.2.Final.jar:]
        at org.apache.chemistry.opencmis.client.util.FileUtils.getObject(
        at com.computas.contentrepo.impl.basic.cmis.CmisBasicContentRepo.getObject(
        at com.computas.contentrepo.impl.basic.cmis.CmisBasicContentRepo.exists(

Reproduces with both 1.0.0-SNAPSHOT pulled today, as well as the stable 0.12: (1.0.0-SNAPSHOT)
protected Response post(UrlBuilder url, String contentType, Output writer) {
        // make the call
        // Log.d("URL", url.toString());
        Response resp = getHttpInvoker().invokePOST(url, contentType, writer, session);

        // check response code
        if (resp.getResponseCode() != 201) {
            throw convertStatusCode(resp.getResponseCode(), resp.getResponseMessage(), resp.getErrorContent(),

        return resp;

The resp looks like an empty one, certainly not one coming from the server, here is why:
- header only has one entry: {content-type=[unknown/unknown]}
- responseCode = -1
- all the other response fields are null
- hasResponseStream = false!


Nicu Marasoiu 
Enterprise Java Architect
+ 40 724746655

-----Original Message-----
From: Florian Müller [] 
Sent: Thursday, October 09, 2014 6:25 PM
Cc: Nicolae Marasoiu
Subject: RE: response code -1 (request not sent?)

Hi Nicu,

Could you please provide a stack trace?
A CmisRuntimeException can be anything. The context and the error message are important.

- Florian

> Hi,
> In fact, calling directly works ok. But calling after some other calls
> have been made (getting objects, creating directories), it fails like
> this.
> Also, creating a new session and doing
> getObjectByPath("/content-1670202666") gives the same result after
> those operations (after creating a folder tree).
> Please advise,
> Nicu Marasoiu
> -----Original Message-----
> From: Nicolae Marasoiu []
> Sent: Thursday, October 09, 2014 12:34 PM
> To:
> Subject: response code -1 (request not sent?)
> Hi,
> session.getObjectByPath("/content-1670202666") throws a
> CmisRuntimeException, wrapping a response code -1 (which is a strange
> one, and I think that actually this is not due to a response coming
> from the server, since the headers is also empty and all fields of
> response are null).
> Making a browser test with the url value which fails:
> "http://localhost:8080/chemistry-opencmis-server-fileshare-1.0.0-SNAPSHOT/atom11/test/path?path=%2Fcontent-1670202666&filter=&includeAllowableActions=true&includeACL=false&includePolicyIds=false&includeRelationships=none&renditionFilter=cmis%3Anone"
> brings a looking code xml with code 200.
> This seems to happen with chemistry client 0.12.0 on both
> FileShare-0.12.0 and Modeshape-4.
> Please advise,
> Nicu

View raw message