proxy_cache_key with variables

xnirchan nginx-forum at nginx.us
Mon Jul 6 14:05:31 UTC 2015


Hi,

>>proxy_cache_key "$upstream_addr*$request";
I am not sure that you are using the correct format for proxy_cache_key
directive.
my I know what is the wildcard char "*" doing out there, between
$upstream_addr and $request?

refer to nginx directive example:
proxy_cache_key "$host$request_uri $cookie_user"; 
or by default is
proxy_cache_key $scheme$proxy_host$uri$is_args$args;

>>I plan to add "load balancing" module, which would be able to forward
request on (multiple) source addresses to multiple proxied addresses, with
caching.. Will it work properly?
if your nginx is acting as load balancer, I guess better add load balancing
module.

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,260086,260088#msg-260088



More information about the nginx mailing list