Welcome! Log In Create A New Profile

Advanced

Re: Will nginx support HTTP Etag ?

Anton Yuzhaninov
April 14, 2009 06:04AM
Xia Qingran wrote:
> After reading http://wiki.nginx.org, I find out that nginx has not the
> offical support for the HTTP Etag,
> http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.19 . I
> want to know whether the future version of nginx will add this
> feature.
>
> My website is taking use of nginx to run static files server including
> lots of Javascipt and CSS files modified frequently. Now I set a very
> short expires time like, expires 1h, to renew the client cache as soon
> as possible.
>
> But I think it is not a good solution. It wastes my network bandwidth
> if I do not modify the static files.

If last-modifed date of file is not changed, bandwidth saved:

client send in request

header If-Modified-Since:

and if time in request same as time of file modification on disk nginx send reply
HTTP/1.x 304 Not Modified

In general Etag for static files is not better than Last-Modified header.

Etag is useful for dynamic content, when modify time is not known. In this case Etage can be
generated from hash (md5/sha) of content.


--
Anton Yuzhaninov
Subject Author Posted

Will nginx support HTTP Etag ?

Xia Qingran April 14, 2009 05:33AM

Re: Will nginx support HTTP Etag ?

Anton Yuzhaninov April 14, 2009 06:04AM

Re: Will nginx support HTTP Etag ?

Phillip B Oldham April 15, 2009 03:37AM

Re: Will nginx support HTTP Etag ?

Anton Yuzhaninov April 15, 2009 05:52AM

Re: Will nginx support HTTP Etag ?

mike April 14, 2009 11:36AM

Re: Will nginx support HTTP Etag ?

Xia Qingran April 14, 2009 10:53PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

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