filter to modify upstream response before it is cached

Roger Fischer roger at netskrt.io
Sat Jan 11 00:57:32 UTC 2020


Hello,

is there a hook into the nginx processing to modify the response body (and headers) before they are cached when using with proxy_pass?

I am aware of the body filters (http://nginx.org/en/docs/dev/development_guide.html#http_body_filters <http://nginx.org/en/docs/dev/development_guide.html#http_body_filters>), running before the response is delivered to the client. But I would prefer to run the filter just once, when the upstream response is cached.

I am assuming, if nginx does not offer such a hook, OpenResty will not be of any help either.

Thanks…

Roger

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20200110/88da4a35/attachment.htm>


More information about the nginx mailing list