Gzip proxied content, where?


#1

Hi,

What is the best practice to gzip content? In the frontend or at the
backend? Wich performs better?

Thanks

Nuno

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


#2

Hello!

On Wed, Jun 03, 2009 at 03:55:41PM -0400, nfn wrote:

Hi,

What is the best practice to gzip content? In the frontend or at the backend? Wich performs better?

From performance point of view - gzipping at backend will allow
you to save some internal network bandwidth. But

  1. It won’t allow you to do frontend processing (ssi, charset
    conversions, xslt, adding headers/footers via addition_module,
    substitutions via sub_module; not sure how this will affect cache
    if used).

  2. If other servers used as backends (not nginx), and gzipping on
    them may be a bad idea since nginx usually faster and more
    efficient.

So general practice is to avoid gzipping on backends and do this
on nginx frontend.

Maxim D.


#3

Hi,

Thank you. I’m running nginx as frontend and apache2/mod_php as backend.

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