Return-Path: X-Original-To: apmail-httpd-users-archive@www.apache.org Delivered-To: apmail-httpd-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 36386713C for ; Thu, 6 Oct 2011 16:37:28 +0000 (UTC) Received: (qmail 90069 invoked by uid 500); 6 Oct 2011 16:37:25 -0000 Delivered-To: apmail-httpd-users-archive@httpd.apache.org Received: (qmail 90035 invoked by uid 500); 6 Oct 2011 16:37:25 -0000 Mailing-List: contact users-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: users@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@httpd.apache.org Received: (qmail 90027 invoked by uid 99); 6 Oct 2011 16:37:25 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Oct 2011 16:37:25 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW X-Spam-Check-By: apache.org Received-SPF: unknown (nike.apache.org: error in processing during lookup of fxn@hashref.com) Received: from [74.125.82.173] (HELO mail-wy0-f173.google.com) (74.125.82.173) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Oct 2011 16:37:17 +0000 Received: by wyh22 with SMTP id 22so4441401wyh.18 for ; Thu, 06 Oct 2011 09:36:57 -0700 (PDT) Received: by 10.227.19.143 with SMTP id a15mr1242469wbb.1.1317919017152; Thu, 06 Oct 2011 09:36:57 -0700 (PDT) MIME-Version: 1.0 Received: by 10.180.96.34 with HTTP; Thu, 6 Oct 2011 09:36:17 -0700 (PDT) From: Xavier Noria Date: Thu, 6 Oct 2011 18:36:17 +0200 Message-ID: To: users@httpd.apache.org Content-Type: multipart/alternative; boundary=002215b03a22dc2f1c04aea3ee3a X-Virus-Checked: Checked by ClamAV on apache.org Subject: [users@httpd] serving pre-compressed content --002215b03a22dc2f1c04aea3ee3a Content-Type: text/plain; charset=UTF-8 Does anyone have a well-tested and idiomatic Apache configuration to serve pre-compressed content? Vary header, Content-Type header, browser gotchas, and everything robustly sorted out? The situation is that you have foo.css and foo.css.gz on disk, and want Apache to serve foo.css.gz directly if asked for foo.css and the clients accepts the compressed content. I guess that's going to be based on content negotiation with MultiViews, but a google search suggests there are practical issues to get this right that may not be obvious at first. And also a curiosity: After all these years, why doesn't mod_deflate do this by itself? Compressing with max ratio to disk on a first request, and serving the cached .gz in subsequent requests? --002215b03a22dc2f1c04aea3ee3a Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Does anyone have a well-tested and idiomatic Apache configuration to serve = pre-compressed content? Vary header, Content-Type header, browser gotchas, = and=C2=A0everything robustly sorted out?

The situat= ion is that you have foo.css and foo.css.gz on disk, and want Apache to ser= ve foo.css.gz directly if asked for foo.css and the clients accepts the com= pressed content.

I guess that's going to be based on content negotia= tion with MultiViews, but a google search suggests there are practical issu= es to get this right that may not be obvious at first.

And also a curiosity: After all these years, why doesn't mod_defla= te do this by itself? Compressing with max ratio to disk on a first request= , and serving the cached .gz in subsequent requests?
--002215b03a22dc2f1c04aea3ee3a--