Welcome! Log In Create A New Profile

Advanced

Re: Migrating from Varnish

Maxim Dounin
November 23, 2017 12:54PM
Hello!

On Thu, Nov 23, 2017 at 10:24:19AM -0600, Andrei wrote:

> > > - Does anyone have any recent working documentation on supported
> > > modules/Lua scripts which can achieve wildcard purges as well as specific
> > > URL purges?
> >
> > Cache purging is available in nginx-plus, see
> > http://nginx.org/r/proxy_cache_purge.
>
> I'm aware of the paid version, but I don't have a budget for it yet, and
> quite frankly this should be a core feature for any caching service. Are
> there no viable options for the community release? It's a rather pertinent
> feature to have in my transition

I'm aware of at least one 3rd party module from Piotr Sikora,
https://github.com/FRiCKLE/ngx_cache_purge. I've never tried to
use it, and AFAIK it doesn't support wildcard purges. It is
mostly known to developers as a hack that starts segfaulting on
unrelated changes in proxy module, so obviously enough I can't
recommend using it.

Note though that I personally think that cache purging is
something that should _not_ be present in any caching service, and
I wouldn't recommend using nginx-plus functionality either.
Proper controlling of cache validity times is something that
should be used instead. This is what happens in browsers anyway,
and trying to "purge" things there won't work.

> > Note well that by default nginx respects what is returned by the
> > backend in various response headers, and proxy_cache_valid time
> > only applies if there are no explicit cache validity time set, see
> > http://nginx.org/r/proxy_ignore_headers.
>
> So to override the ttls set by the backend, I would have to use
> proxy_ignore_headers for all headers which can directly affect the intended
> TTL?

Yes, if you want to ignore what the backend set. In many cases
this might not be a good idea though.

--
Maxim Dounin
http://mdounin.ru/
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Migrating from Varnish

Andrei November 23, 2017 10:02AM

Re: Migrating from Varnish

Andrei November 23, 2017 10:26AM

Re: Migrating from Varnish

Maxim Dounin November 23, 2017 10:58AM

Re: Migrating from Varnish

Andrei November 23, 2017 11:26AM

Re: Migrating from Varnish

itpp2012 November 23, 2017 12:53PM

Re: Migrating from Varnish

Maxim Dounin November 23, 2017 12:54PM

Re: Migrating from Varnish

Andrei November 23, 2017 03:34PM

Re: Migrating from Varnish

Andrei November 23, 2017 03:36PM

Re: Migrating from Varnish

itpp2012 November 23, 2017 04:51PM

Re: Migrating from Varnish

Andrei November 30, 2017 01:10AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 59
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready