Suppose you get a scenario where you have to design a proxy which gives a JSON response or XML response based on the 'Accept' Header. If the user of the proxy sends, Accept header = application.json, you should gives JSON response, if he sends application/xml, you should guve XML response. If you have added a response cache in such a proxy, you will run into some issues
1.) If the user expects a JSON response, a JSON output would be stored in the cache.
2.) Now when the user expects an XML response, because the response cache is present in both the request and response flow, it will first hit the response cache and you will get a JSON response instead of an XML response.
The solution to this, is to use a small but a valuable property while configuring response cache. <UseAcceptHeader>true</UseAcceptHeader>
In this case, the accept header would be suffixed to your cache key, which will help the cache distinguish between different types of responses.
Customized APIs by device - Belly
Sample: Using Node.js caching with Edge policies
Tutorial: Implementing Response Caching within Edge
How to dynamically call different target endpoints based on region
Apigee Developer? Here's The Stuff You Should Know
Using the ResponseCache policy responsibly! (or, Don't cache POST requests)
Automate KVM creation on Apigee Edge
Quick way to find the Developer App associated with a particular Consumer Key
Handling invalid Resource Paths using a default Resource and the Raise Fault policy