Problem solved.

because of missing content-length

adding following two property to  <outSequence> for each API.

<property name="COPY_CONTENT_LENGTH_FROM_INCOMING" value="true"
scope="axis2"/><property name="FORCE_HTTP_CONTENT_LENGTH"
scope="axis2" value="true"></property>

any way to make this changes centralize?

Regards,
James Ong

On Mon, Nov 7, 2016 at 10:06 PM, James Ong <comcr...@gmail.com> wrote:

> Hi Lakshani,
>
> Based on the debug output, the only difference I suspect is outgoing
> request is using chunked data.
>
> Any possible to just pass the same format as input ?
>
> TID: [0] [AM] [2016-11-07 17:34:28,316] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "POST /authUser/1.0.1
> HTTP/1.1[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,317] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Host:
> gogolf.my:8243[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,317] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Connection:
> keep-alive[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,317] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Content-Length:
> 142[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,317] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "User-Agent: Mozilla/5.0
> (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko)
> Chrome/54.0.2840.87 Safari/537.36[\r][\n]" {org.apache.synapse.transport.
> http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,318] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Origin:
> chrome-extension://apcedakaoficjlofohhcmkkljehnmebp[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,318] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Authorization: Bearer
> 307de5aba12252160bd6afbefcb9673[\r][\n]" {org.apache.synapse.transport.
> http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,318] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Content-Type:
> application/json[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,318] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Accept: */*[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,318] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Accept-Encoding: gzip,
> deflate, br[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,319] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Accept-Language:
> en-US,en;q=0.8,zh-CN;q=0.6,zh;q=0.4,zh-TW;q=0.2,ms;q=0.2[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,319] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Cookie:
> roundcube_cookies=enabled; __utma=246744978.472091108.
> 1476716658.1478187773.1478356567.13; __utmz=246744978.1477745778.1.
> 1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); 
> _ga=GA1.2.472091108.1476716658;
> __unam=7974974-158108304d3-5d7b376d-349; region3_registry_menu=visible;
> menuPanel=visible; menuPanelType=config; region1_configure_menu=visible;
> i18next=en-US; UserFrosting=c494rtv2r3ctf7kg40msgl3716[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,319] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,319] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "{[\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,320] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "  "authUserRequest":
> {[\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,320] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "    "requestTimestamp":
> "20160920131022930",[\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,320] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "    "username": "
> x...@yahoo.com",[\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,320] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "    "password":
> "xxxx.xxxx"[\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,320] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "  }[\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,321] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "}[\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,328] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "POST
> http://gogolf.my/members/api/authUser/ HTTP/1.1[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,330] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Accept-Language:
> en-US,en;q=0.8,zh-CN;q=0.6,zh;q=0.4,zh-TW;q=0.2,ms;q=0.2[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,330] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Cookie:
> roundcube_cookies=enabled; __utma=246744978.472091108.
> 1476716658.1478187773.1478356567.13; __utmz=246744978.1477745778.1.
> 1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); 
> _ga=GA1.2.472091108.1476716658;
> __unam=7974974-158108304d3-5d7b376d-349; region3_registry_menu=visible;
> menuPanel=visible; menuPanelType=config; region1_configure_menu=visible;
> i18next=en-US; UserFrosting=c494rtv2r3ctf7kg40msgl3716[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,330] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Accept-Encoding: gzip,
> deflate, br[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,331] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Origin:
> chrome-extension://apcedakaoficjlofohhcmkkljehnmebp[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,331] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Content-Type:
> application/json[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,331] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Accept: */*[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,331] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Transfer-Encoding:
> chunked[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,332] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Host:
> gogolf.my:80[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,332] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "Connection:
> Keep-Alive[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,332] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "User-Agent:
> Synapse-PT-HttpComponents-NIO[\r][\n]" {org.apache.synapse.transport.
> http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,332] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,332] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "8e[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,333] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "{[\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,333] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "  "authUserRequest":
> {[\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,333] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "    "requestTimestamp":
> "20160920131022930",[\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,333] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "    "username": "
> x...@yahoo.com",[\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,333] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "    "password":
> "xxxx.xxxx"[\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,334] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "  }[\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,334] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "}[\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,334] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,334] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "0[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,334] DEBUG
> {org.apache.synapse.transport.http.wire} -  << "[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,444] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "HTTP/1.1 200 OK[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,444] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Date: Mon, 07 Nov 2016
> 09:34:28 GMT[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,444] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Server: Apache[\r][\n]"
> {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,444] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Vary:
> Accept-Encoding[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,445] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Content-Encoding:
> gzip[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,445] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Content-Length:
> 139[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,445] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Keep-Alive: timeout=5,
> max=100[\r][\n]" {org.apache.synapse.transport.http.wire}
> TID: [0] [AM] [2016-11-07 17:34:28,445] DEBUG
> {org.apache.synapse.transport.http.wire} -  >> "Connection:
> Keep-Alive[\r][\n]" {org.apache.synapse.transport.http.wire}
>
> Regards,
> James Ong
>
> On Mon, Nov 7, 2016 at 12:06 PM, Lakshani Gamage <laksh...@wso2.com>
> wrote:
>
>> Hi James,
>>
>> Please enable wire logs and post logs[1].
>>
>> [1] http://lakshanigamage.blogspot.com/2015/03/how-to-enable-
>> wire-logs-in-wso2-esbapim.html
>>
>> Thanks,
>> Lakshani.
>>
>> On Mon, Nov 7, 2016 at 6:28 AM, James Ong <comcr...@gmail.com> wrote:
>>
>>> Hi all,
>>>
>>> I am facing one issue and hope this forum can assist me.
>>>
>>> I have a PHP web application that got one service accept JSON as
>>> payload. I am using ARC for chorme for my testing. When I call the service
>>> direct to my web app, everything work fine.
>>>
>>> However, when I trigger the service via API manager, the request did
>>> reach my app, but the JSON payload is missing. Any idea why this happen?
>>>
>>> Thank you.
>>>
>>> Regards,
>>> James Ong
>>>
>>> _______________________________________________
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Lakshani Gamage
>>
>> *Software Engineer, WSO2*
>>
>> *Mobile : +94 71 5478184 <%2B94%20%280%29%20773%20451194>*
>> *Blog : http://lakshanigamage.blogspot.com/
>> <http://lakshanigamage.blogspot.com/>*
>>
>
>
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to