502 Bad Gateway error

Hi Guys ,

My Json request from postman is reaching to backed server via apigee proxy then back end is responding with response. but apigee can't able to get response and give 

HeaderWithInvalidChar error. Iam sending few parameters in header without any space from postman.
Below is the screenshot of tracing proxy. Proxy returns 502 Bad Gateway error.

I copied generated curl from proxy and use this curl command from Apigee gateway server.
I can receive correct output from backend.

Can any one having any idea on this.

Apigee issue.png

Thanks,
Mahesh

0 4 1,329
4 REPLIES 4

It appears to me that Apigee believes that the header name is 

origin,content-type,accept,authorization,userid...

And that looks odd. It's not valid to have commas in the header name. What's odd is the name is a concatenation of actual valid header names. Something slightly askew there.

The policy that runs JUST BEFORE that point in the trace.... what does it do?  Is that an AssignMessage? Can you show the configuration?  Is it possible you have a misconfiguration there which is injecting a header with a really strange (and invalid) name?  

Apigee issue1.png

 

 

 

 

 

 

 

 

 

 

 

 

Thanks,

Mahesh

 

Hi @dchiesa1 

mmahesh1417_0-1634442739351.png

 

Hi,

After start tracing the proxy , i captured Curl Command from proxy, then i executed from my apigee server i can able to get correct response. Below is pic of curl from proxy.

Apigee issue2.png

 

Thanks,

Mahesh