If-Modified-Since

Dag-Erling Smørgrav des at linpro.no
Tue Aug 15 09:28:20 CEST 2006


Arne managed to get a trace of an HTTP session where Varnish
incorrectly sent a 304 reply to an If-Modified-Since request.

The object in his browser cache was:

> HTTP/1.1 200 OK
> Date: Mon, 14 Aug 2006 13:30:28 GMT
> Server: Apache/1.3.27 (Unix)
> Cache-Control: max-age=900
> Expires: Mon, 14 Aug 2006 13:45:28 GMT
> Last-Modified: Mon, 14 Aug 2006 13:30:03 GMT
> Etag: "2b400e-24922-44e07adb"
> Content-Type: text/html; charset=iso-8859-1
> Content-Length: 149794
> X-Varnish: 44998368 44998332
> Age: 20
> Via: 1.1 varnish

the request sent by his browser:

> GET / HTTP/1.1
> Host: vg.no
> User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.8.0.5) Gecko/20060727 Ubuntu/dapper-security Firefox/1.5.0.5
> Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
> Accept-Language: en-us,en;q=0.5
> Accept-Encoding: gzip,deflate
> Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
> Keep-Alive: 300
> Connection: keep-alive
> If-Modified-Since: Mon, 14 Aug 2006 13:30:03 GMT
> If-None-Match: "2b400e-24922-44e07adb"
> Cache-Control: max-age=0

the reply from Varnish:

> HTTP/1.1 304 Not Modified
> Via: 1.1 varnish
> X-Varnish: 44998848
> Last-Modified: Mon, 14 Aug 2006 13:30:03 GMT

(note that the reply lacks a Date: header, we should fix that as well)

unfortunately, I don't have the corresponding Varnish log.

DES
-- 
Dag-Erling Smørgrav
Senior Software Developer
Linpro AS - www.linpro.no



More information about the varnish-dev mailing list