What would cause a proxy to stop forwarding headers?

As recently as yesterday I was leveraging a proxy that forwarded headers along with the HTTP request, but today the headers are being dropped.   There have been no changes to the proxy that I can see.  If I take the proxy out of the mix, the call succeeds.  What could cause something like this?

0 3 391
3 REPLIES 3

I started a debug session and when i click the 'show curl' on Request sent to target server step, i get a curl with no headers, even though headers were sent and they are not being removed by anything.  was working as recently as yersterday

Need more data as it is not possible to get headers dropped with in apigee unless you have assign variable to explicitly add assign to remove headers(https://docs.apigee.com/api-platform/reference/policies/assign-message-policy#remove). Please check the code or share the bundle for review but it is unusual behavior.

I cannot imagine what would cause that. 

Apigee at runtime acts as a reverse proxy.  When you create an API proxy, it starts as a "pass-through", which means the request that arrives at the Apigee gateway, is the same as the request that gets forwarded to the upstream system.  If you don't change any of the Apigee proxy configuration, then that's what happens. You need to take special action to tell Apigee to NOT forward headers to the upstream. 

If you're not seeing headers, there's probably a policy executing at some point in the request context that modifies the headers, or strips headers out of the outbound request. This CAN happen via a sharedflow+ flowhook, such that even if you never modify your API proxy, its behavior might change.  

To diagnose what's happening I recommend starting a debug session, to examine the steps that get executed. You should be able to view the headers arriving in with the inbound request, and any modifications to that request (including adding or removing headers, modifying the payload, path, or method, etc), before it is proxied to the upstream system.