the age penalty and its effect on cache performance

21
USITS ‘01 The Age Penalty and its effect on cache performance Edith Cohen AT&T Labs- Research Haim Kaplan Tel-Aviv University Presenting: Edith Cohen

Upload: lea

Post on 05-Jan-2016

38 views

Category:

Documents


0 download

DESCRIPTION

The Age Penalty and its effect on cache performance. Haim Kaplan Tel-Aviv University. Edith Cohen AT&T Labs-Research. Presenting: Edith Cohen. Distribution of Web Content. cache. cache. Origin server. Content of URL can be modified by the origin. Copies are cached throughout. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: The Age Penalty and its effect on cache performance

USITS ‘01

The Age Penalty and its effect on cache performance

Edith Cohen

AT&T Labs-Research

Haim Kaplan

Tel-Aviv University

Presenting: Edith Cohen

Page 2: The Age Penalty and its effect on cache performance

USITS ‘01

Distribution of Web Content

Origin server

cache cache

•Content of URL can be modified by the origin. •Copies are cached throughout

Page 3: The Age Penalty and its effect on cache performance

USITS ‘01

HTTP Freshness Control

• Cached copies have:– Freshness lifetime– Age (elapsed time since fetched from

origin)

• TTL (Time to Live) = freshness lifetime – age• Expired copies must be validated

before they can be used.

Body(content)

headerCache-directives

Page 4: The Age Penalty and its effect on cache performance

USITS ‘01

HTTP Cache Serving a Request

•No cached copy GET a fresh copy •Stale cached copy If-Modified-Since GET a fresh copy

•“Not-Modified” update header •“Modified” update content and header

•Fresh cached copy

GET www.cnn.com/WEATHER/

Page 5: The Age Penalty and its effect on cache performance

USITS ‘01

“hits” and “misses”

hit-rate metric: c-hit/(c-hit+c-miss)latency(c-miss) > latency(f-miss) >> latency(f-

hit) “hit-rate” does not capture freshness

freshness-rate: f-hit/c-hit

f-hit f-miss c-miss

remote RTTs X X

content-transfer X

“traditional”: c-hit (hit) (miss)

Page 6: The Age Penalty and its effect on cache performance

USITS ‘01

“Value” of a Cached Copy• Frequency/pattern of requests• Size (storage cost)• Fetching cost (latency/bandwidth)• Modification rate (likelihood of c-miss)• Age (likelihood of f-miss)Important issues for:•replacement and pre-fetching strategies•cascaded caches

Page 7: The Age Penalty and its effect on cache performance

USITS ‘01

Origin Server to User

www.cnn.com

reverse proxy

reverse proxy

reverse proxy

proxy cache

proxy cache

AS

AS

Page 8: The Age Penalty and its effect on cache performance

USITS ‘01

Issues for Cascaded Caches

• Path between Web server and end-user often includes 2 or more caches.

• downstream cache sends older copies more misses at upstream caches– more traffic between caches

– increased user-perceived latency

Page 9: The Age Penalty and its effect on cache performance

USITS ‘01

1:00pm

Freshness-lifetime= 10 HAge = 0

Distributing Copies

Origin server

downstream cache upstream cache

7:00pm

Freshness-lifetime= 10 HAge = 6 H

Freshness-lifetime= 10 HAge = 9:59 H

10:59pm

Page 10: The Age Penalty and its effect on cache performance

USITS ‘01

Modeling Sources of a Cache

•“Cache” misses are forwarded to a cache

Cache-2

www.cnn.com

Cache

Cache-1

•“Origin” misses are forwarded to authoritative (origin) server.

Page 11: The Age Penalty and its effect on cache performance

USITS ‘01

Source Models…

•origin: age(t) = 0 •cache: age(t) = T - (t+a) mod T

Object with freshness-lifetime = T. The age of copy retrieved at time t is:

Theorem: miss_origin(S) < miss_cache(S) < 2*miss_origin(S)

Request sequence S

Age-Penalty)(

)()()(

Sfrate

SfrateSfrateS

cache

cacheorigin

Definition:

Page 12: The Age Penalty and its effect on cache performance

USITS ‘01

…Age-penalty

Requests:

cache

T

t

TTLorigin

m f-mhm f-m f-m

Page 13: The Age Penalty and its effect on cache performance

USITS ‘01

Trace-driven Simulations

log Origin Cache penalty

NLANR UC 52% 43% 21%

NLANR SD 47% 38% 24%

freshness-rate for different configurations

Page 14: The Age Penalty and its effect on cache performance

USITS ‘01

CDN server

CDN server

CDN server

Content Delivery Network

www.cnn.com

AS

Page 15: The Age Penalty and its effect on cache performance

USITS ‘01

Content Delivery Networks•CDN servers are a system of reverse proxy caches, placed throughout the Internet.•Proprietary, non-HTTP, freshness control between origin and CDN servers, allowing for longer TTL durations.

CDNwww.cnn.com Cache

•HTTP freshness control•Proprietary freshness control

Page 16: The Age Penalty and its effect on cache performance

USITS ‘01

CDN Age-Handling PracticesPractice: “Intact headers” CDN servers act as a cache, end-to-end headers are intact. (-3/2000).What are the implications?Practice: “emulate origin” CDN servers rewrite age to 0 (3/2000-present)

Practice: “equate lifetime” CDN servers rewrite HTTP freshness lifetime is equated (extended) to “proprietary” freshness lifetime.How much can be gained?

Page 17: The Age Penalty and its effect on cache performance

USITS ‘01

…Implications of Intact Headers

Age = time on CDN server copies often served with 0 TTL!

Page 18: The Age Penalty and its effect on cache performance

USITS ‘01

…Implications of Intact Headers

CDN NLANR log

%requests

Freshness-rate

CDN origin

Sandpiper UC 0.4% 5% 76%

Sandpiper SD 0.5% 6% 67%

Akamai UC 1.7% 5% 61%

Akamai SD 1.1% 6% 63%

Page 19: The Age Penalty and its effect on cache performance

USITS ‘01

…..Equating Lifetimes

How much can be gained?

We estimate about 20% of requeststo CDN (Akamai) servers would beeliminated.

Page 20: The Age Penalty and its effect on cache performance

USITS ‘01

Conclusion• Content-aging can have significant performance

effect on cascaded Web caches (25% decrease in effectiveness of cache hits).

• Aging effects are not being carefully accounted for (see CDN practices).

• Content-aging warrants more awareness by practitioners, and more research...

Page 21: The Age Penalty and its effect on cache performance

USITS ‘01

Follow-up Work• More “source” types (e.g., alternating between several

downstream caches)• Pre-term refreshes by downstream cache

(sporadic updates by downstream cache may decrease performance, but this can be avoided)

• Longer lifetime durations at upstream caches (tradeoff of staleness and latency)

• Rejuvenation by downstream caches (refresh “fresh” popular copies to set their age to 0). Proper use can improve performance, but otherwise can decrease performance (!!!)…