mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged HEAD-BUG-FIX (4.3/Cloud) to HEAD (4.3/Cloud)
68110: Merged V4.2-BUG-FIX (4.2.3) to HEAD-BUG-FIX (4.3/Cloud) 65912: Merged V4.1-BUG-FIX (4.1.9) to V4.2-BUG-FIX (4.2.2) 65770: Merged DEV to V4.1-BUG-FIX (4.1.9) 63441: MNT-10334 : Unable to Sync To Cloud in 4.1.7 only Fixed debug logging info for RemoteConnectorServiceImpl class. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@68398 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (C) 2005-2012 Alfresco Software Limited.
|
* Copyright (C) 2005-2014 Alfresco Software Limited.
|
||||||
*
|
*
|
||||||
* This file is part of Alfresco
|
* This file is part of Alfresco
|
||||||
*
|
*
|
||||||
@@ -39,6 +39,7 @@ import org.apache.commons.httpclient.HttpMethodBase;
|
|||||||
import org.apache.commons.httpclient.ProxyHost;
|
import org.apache.commons.httpclient.ProxyHost;
|
||||||
import org.apache.commons.httpclient.UsernamePasswordCredentials;
|
import org.apache.commons.httpclient.UsernamePasswordCredentials;
|
||||||
import org.apache.commons.httpclient.auth.AuthScope;
|
import org.apache.commons.httpclient.auth.AuthScope;
|
||||||
|
import org.apache.commons.httpclient.methods.ByteArrayRequestEntity;
|
||||||
import org.apache.commons.httpclient.methods.EntityEnclosingMethod;
|
import org.apache.commons.httpclient.methods.EntityEnclosingMethod;
|
||||||
import org.apache.commons.httpclient.methods.StringRequestEntity;
|
import org.apache.commons.httpclient.methods.StringRequestEntity;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
@@ -181,8 +182,21 @@ public class RemoteConnectorServiceImpl implements RemoteConnectorService
|
|||||||
{
|
{
|
||||||
logger.debug("Header: " + hdr );
|
logger.debug("Header: " + hdr );
|
||||||
}
|
}
|
||||||
|
Object requestBody = request.getRequestBody();
|
||||||
|
if (requestBody instanceof StringRequestEntity)
|
||||||
|
{
|
||||||
StringRequestEntity re = (StringRequestEntity)request.getRequestBody();
|
StringRequestEntity re = (StringRequestEntity)request.getRequestBody();
|
||||||
logger.debug("Payload: " + re.getContent());
|
logger.debug("Payload (string): " + re.getContent());
|
||||||
|
}
|
||||||
|
else if (requestBody instanceof ByteArrayRequestEntity)
|
||||||
|
{
|
||||||
|
ByteArrayRequestEntity re = (ByteArrayRequestEntity)request.getRequestBody();
|
||||||
|
logger.debug("Payload (byte array): " + re.getContent().toString());
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
logger.debug("Payload is not of a readable type.");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Perform the request, and wrap the response
|
// Perform the request, and wrap the response
|
||||||
|
Reference in New Issue
Block a user