As part of processing a request, I need to first send and receive a response to/from an upstream to authenticate some credentials in the request. Once this has been done, the original request needs to be proxied to another upstream.
According to Evan Miller's tutorial, the only valid location for spawning sub-requests is in an output filter ie. to post-process a response. So it appears that this approach is useful for massaging a reponse but not valid for actually performing pre-processing on a request.
Does anyone know what the sanctioned way of going about this in NGINX is? Or which existing modules/examples implement similar functionality?
- Andrew