Nginx-lua Dynamic location to upstream

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
Report Content as Inappropriate

Nginx-lua Dynamic location to upstream

Hi there,
I've Just started to play with Lua (with nginx-plus) and this is what I'd
like to achieve:
I expose a location and a lua script Will inspect http args.Once It takes
the args,It Will call an external api searching for a specific content and
It Will writes the returned json values on some lua variables.
Based on the returned values,Nginx Will proxy_pass to the right upstream.
Does Nginx/luajit cache all json values/pages based on different calls?I
don't really want to call an external api for every single location
Thanks a lot.

Posted at Nginx Forum: https://forum.nginx.org/read.php?2,273136,273136#msg-273136

nginx mailing list
[hidden email]