Skip to Main Content
High Performance Web Sites
book

High Performance Web Sites

by Steve Souders
September 2007
Intermediate to advanced content levelIntermediate to advanced
170 pages
4h 24m
English
O'Reilly Media, Inc.
Content preview from High Performance Web Sites

ETags in the Real World

Table 15-1 shows that 6 out of 10 top U.S. web sites use ETags on a majority of their components. To be fair, three of them have modified the ETag format to remove inode (Apache) or ChangeNumber (IIS). Four or more contain ETags that haven't been modified and therefore cause the performance problems discussed previously.

Table 15-1. ETags observed across 10 top web sites

Web Site

Components with ETags

Fixed

http://www.amazon.com

0% (0/24)

n/a

http://www.aol.com

5% (3/63)

yes

http://www.cnn.com

83% (157/190)

no

http://www.ebay.com

86% (57/66)

no

http://www.google.com

0% (0/5)

n/a

http://www.msn.com

72% (42/58)

no

http://www.myspace.com

84% (32/38)

yes and no

http://www.wikipedia.org

94% (16/17)

unknown

http://www.yahoo.com

0% (0/34)

n/a

http://www.youtube.com

70% (43/61)

yes

An example of a component with different ETags across the cluster of servers is http://stc.msn.com/br/hp/en-us/css/15/blu.css from http://msn.com. The HTTP headers from the first request in the example contains an ETag value of 80b31d5a4776c71:6e0.

GET /br/hp/en-us/css/15/blu.css HTTP/1.1
Host: stc.msn.com

HTTP/1.1 200 OK
Last-Modified: Tue, 03 Apr 2007 23:25:23 GMT
ETag: "80b31d5a4776c71:6e0"
Content-Length: 647
Server: Microsoft-IIS/6.0

On the first reload, the ETag matches and a 304 response is sent. The Content-Length header is missing from the response because the 304 status code tells the browser to use the content from its cache.

GET /br/hp/en-us/css/15/blu.css HTTP/1.1 Host: stc.msn.com If-Modified-Since: Tue, 03 Apr ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Even Faster Web Sites

Even Faster Web Sites

Steve Souders
Back-end Performance

Back-end Performance

Bruno Skvorc, Christopher Pitt, Tonino Jankov, Reza Lavaryan, Daniel Berman

Publisher Resources

ISBN: 9780596529307Errata Page