Welcome! Log In Create A New Profile

Advanced

Re: Nginx multiple upstream map conditions

Francis Daly
August 31, 2016 05:58PM
On Wed, Aug 31, 2016 at 01:30:30PM -0400, c0nw0nk wrote:

Hi there,

> Thanks works a treat is it possible or allowed to do the following in a
> nginx upstream map ? and if so how i can't figure it out.

I think it is logically impossible.

> I cache with the following key.
> fastcgi_cache_key
> "$session_id_value$scheme$host$request_uri$request_method";

fastcgi_cache_key is the thing that nginx calculates from the request,
before it decides whether to send the response from cache, or whether
to pass the request to upstream.

> if the upstream_cookie_logged_in value is not equal to 1 how can I set
> $session_id_value ''; make empty

$upstream_cookie_something is part of the response from upstream,
so is not available to nginx at the time that it is calculating
fastcgi_cache_key for the "read from cache or not" decision.

Am I missing something?

f
--
Francis Daly francis@daoine.org

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Nginx multiple upstream map conditions

c0nw0nk August 30, 2016 02:25PM

Re: Nginx multiple upstream map conditions

Valentin V. Bartenev August 31, 2016 07:06AM

Re: Nginx multiple upstream map conditions

c0nw0nk August 31, 2016 01:30PM

Re: Nginx multiple upstream map conditions

c0nw0nk August 31, 2016 01:42PM

Re: Nginx multiple upstream map conditions

Francis Daly August 31, 2016 05:58PM

Re: Nginx multiple upstream map conditions

c0nw0nk August 31, 2016 06:44PM

Re: Nginx multiple upstream map conditions

c0nw0nk August 31, 2016 09:17PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 143
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready