Welcome! Log In Create A New Profile

Advanced

memcache_assume_gzipped for 1.2.6

Daniel Church
December 20, 2012 02:52PM
I'm running nginx on a cheap VPS, which has pretty horrible disk i/o. As
such I keep most of my content in memcached so that nginx never has to hit
the disk, a good mix of cached dynamic and cached static content. I wanted
to use GZIP compression without wasting CPU cycles gzipping memcached
content over and over again.

I created a flag "memcache_assume_gzipped" to the memcache module. If you
turn it on for a location, it will append "Content-type: gzip" to the
headers of the response inside the memcache module. This way, you can gzip
content (level 9), store it straight into memcache, and then nginx will
return it with the appropriate headers. Example here:

http://alpha.criticalmeltdown.com/demo/2

Is this something anyone is interested in incorporating into the current
stable branch, or is it too much of a niche need? If anyone wants it, I
can throw together a patch file.

Thanks,
Dan
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

memcache_assume_gzipped for 1.2.6

Daniel Church 1003 December 20, 2012 02:52PM

Re: memcache_assume_gzipped for 1.2.6

Maxim Dounin 476 December 20, 2012 05:04PM

Re: memcache_assume_gzipped for 1.2.6

Daniel Church 499 December 20, 2012 05:10PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 175
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