Download presentation
Presentation is loading. Please wait.
Published byBrice Kennedy Modified over 9 years ago
1
1 Cache Me If You Can
2
NUS.SOC.CS5248 OOI WEI TSANG 2 You Are Here Network Encoder Sender Middlebox Receiver Decoder
3
NUS.SOC.CS5248 OOI WEI TSANG 3 Cache Proxies for Web A
4
NUS.SOC.CS5248 OOI WEI TSANG 4 Hierarchical Caching A B
5
NUS.SOC.CS5248 OOI WEI TSANG 5 Cooperative Caching AB
6
NUS.SOC.CS5248 OOI WEI TSANG 6 Distributed Caching AB
7
NUS.SOC.CS5248 OOI WEI TSANG 7 Streaming Media vs. Web Pages
8
NUS.SOC.CS5248 OOI WEI TSANG 8 Video Access Pattern by S. Acharya and B. Smith Study at Lulea University, Sweden 55% complete, 45% stop very early High temporal locality
9
NUS.SOC.CS5248 OOI WEI TSANG 9 Bimodal Distribution
10
NUS.SOC.CS5248 OOI WEI TSANG 10 Zipf Distribution log (Frequency) log (rank) Frequency = C/rank m
11
NUS.SOC.CS5248 OOI WEI TSANG 11 Zipf Law Frequency of English Words “the” “of” “to” “a” City size
12
12 Benefits of Caching
13
NUS.SOC.CS5248 OOI WEI TSANG 13 Reduce Access Latency :):(
14
NUS.SOC.CS5248 OOI WEI TSANG 14 Reduce Server Load
15
NUS.SOC.CS5248 OOI WEI TSANG 15 Buy Some Time
16
NUS.SOC.CS5248 OOI WEI TSANG 16 Reduce Client Buffer Size
17
17 Type of Cache
18
NUS.SOC.CS5248 OOI WEI TSANG 18 Types of Cache Static caching Dynamic caching patching buffer
19
NUS.SOC.CS5248 OOI WEI TSANG 19 Static Caching Cache “all or nothing” is bad Split video into segments of size S
20
NUS.SOC.CS5248 OOI WEI TSANG 20 If I am writing a survey Introduction Differences between web and media caching Video access pattern Benefits of caching Different type of cache Proxy caching architecture
21
NUS.SOC.CS5248 OOI WEI TSANG 21 Other Caching Issues How to segment? Which segments to cache? When to fetch data? Who to fetch from? When cache is full, who to kick out? How to measure popularity? Can cache adapt to popularity?
22
NUS.SOC.CS5248 OOI WEI TSANG 22 Rest of the Lecture Soccer – cooperative caching proxy Silo, rainbow and cache token – distributed caching proxy Mocha – with congestion control
23
23 SOCCER Self-organizing cooperative caching architecture
24
NUS.SOC.CS5248 OOI WEI TSANG 24 How to segment?
25
NUS.SOC.CS5248 OOI WEI TSANG 25 Effects of Size S Large S : Low utilization Small S : Lots of gaps
26
NUS.SOC.CS5248 OOI WEI TSANG 26 Prefix Caching Policy 1 Chunk = k segments
27
NUS.SOC.CS5248 OOI WEI TSANG 27 Fetching Cache Data B A Server Client 2Client 1
28
NUS.SOC.CS5248 OOI WEI TSANG 28 Option 2 B A Server Client 2Client 1
29
NUS.SOC.CS5248 OOI WEI TSANG 29 Option 3 B A Server Client 2Client 1
30
NUS.SOC.CS5248 OOI WEI TSANG 30 Issues How to advertise? How to choose helper?
31
NUS.SOC.CS5248 OOI WEI TSANG 31 How to Advertise? Balance between network load freshness of information
32
NUS.SOC.CS5248 OOI WEI TSANG 32 Scalable Advertisement Expanding Ring Advertisement 16 32 64 128
33
NUS.SOC.CS5248 OOI WEI TSANG 33 How to Choose Helper? Consideration for Static Cache network distance (1,2,3,4) number of streams being served
34
NUS.SOC.CS5248 OOI WEI TSANG 34 Static Cache Cost for retrieving data from node X to node Y =
35
NUS.SOC.CS5248 OOI WEI TSANG 35 Dynamic Caching Need to consider the size of patching buffer S
36
NUS.SOC.CS5248 OOI WEI TSANG 36 Dynamic Caching N used N fetched = min(s, N used + Δ) S
37
NUS.SOC.CS5248 OOI WEI TSANG 37 Dynamic Cache Potential Waste = N fetched /N used Integrate into overall cost
38
NUS.SOC.CS5248 OOI WEI TSANG 38 Helper Selection Helper ask other helpers to help if segments not found on local cache Pick lowest cost helper
39
NUS.SOC.CS5248 OOI WEI TSANG 39 If Static Cache Retrieve to fill current gap May pick different helpers for different gaps Should avoid frequent switching
40
NUS.SOC.CS5248 OOI WEI TSANG 40 If Dynamic Cache Stick to one helper
41
NUS.SOC.CS5248 OOI WEI TSANG 41 Evaluations SOCCER Hierarchical Proxies Single Proxy
42
42 Silo, Rainbow and Cache Token
43
NUS.SOC.CS5248 OOI WEI TSANG 43 Distributed Caching B A Server new clip!
44
NUS.SOC.CS5248 OOI WEI TSANG 44 Distributed Caching B A Server
45
NUS.SOC.CS5248 OOI WEI TSANG 45 Distributed Caching B A Server
46
NUS.SOC.CS5248 OOI WEI TSANG 46 Distributed Caching B A Server
47
NUS.SOC.CS5248 OOI WEI TSANG 47 Cooperative vs Distributed Cooperative caching caches independently Distributed caching caches as a team
48
NUS.SOC.CS5248 OOI WEI TSANG 48 Problems Who should cache what? Which segment to kick out? How to redistribute data?
49
NUS.SOC.CS5248 OOI WEI TSANG 49 RCache N p proxies video of length L v divide into N s equal segments Each proxy caches each segment with a/N p probability
50
NUS.SOC.CS5248 OOI WEI TSANG 50 Analysis Probability that whole video is cached Storage requirement aL
51
NUS.SOC.CS5248 OOI WEI TSANG 51 Two Parameters How to divide video into segments? What is the probability of storing each segment?
52
NUS.SOC.CS5248 OOI WEI TSANG 52 Silo segment size probability of storage
53
NUS.SOC.CS5248 OOI WEI TSANG 53 Problems Who should cache what? Which segment to kick out? How to redistribute data?
54
NUS.SOC.CS5248 OOI WEI TSANG 54 Compute Popularity For each video For each segment
55
NUS.SOC.CS5248 OOI WEI TSANG 55 Rainbow Algorithm less popular
56
NUS.SOC.CS5248 OOI WEI TSANG 56 Problems Who should cache what? Which segment to kick out? How to redistribute data?
57
NUS.SOC.CS5248 OOI WEI TSANG 57 Data Redistribution When popularity changes, need to redistribute. Redistribute “on-demand” (lazy)
58
NUS.SOC.CS5248 OOI WEI TSANG 58 Cache Token Each segment have two bits (T,C) T: I am suppose to have the segment C: I have the segment
59
NUS.SOC.CS5248 OOI WEI TSANG 59 Data Redistribution (T=1,C=1) (T=0,C=0) (T=1,C=0) (T=0,C=1)
60
NUS.SOC.CS5248 OOI WEI TSANG 60 Silo, Rainbow and Token Distributed Caching Architecture Fault tolerant Scalable
61
61 Proxy Cache + Congestion Control
62
NUS.SOC.CS5248 OOI WEI TSANG 62 Scenario (10am) A Server Client 2
63
NUS.SOC.CS5248 OOI WEI TSANG 63 Scenario (1am) A Server Client 2
64
NUS.SOC.CS5248 OOI WEI TSANG 64 Problem Cache interfere with congestion control algorithm Make cache adapt aware of quality adaptation
65
NUS.SOC.CS5248 OOI WEI TSANG 65 Congestion Control Protocol RAP: AIMD + Layered Coding “sender-driven layered unicast”
66
NUS.SOC.CS5248 OOI WEI TSANG 66 Solutions Making cache “quality-aware” Prefetch Replacement Algorithm
67
NUS.SOC.CS5248 OOI WEI TSANG 67 Cache Miss A Server Client 2
68
NUS.SOC.CS5248 OOI WEI TSANG 68 Cache Hit A Server Client 2 repair + prefetch
69
NUS.SOC.CS5248 OOI WEI TSANG 69 Peeking Inside the Cache
70
NUS.SOC.CS5248 OOI WEI TSANG 70 Cache Hit: Repair
71
NUS.SOC.CS5248 OOI WEI TSANG 71 Cache Hit: Prefetch
72
NUS.SOC.CS5248 OOI WEI TSANG 72 Cache Hit: Prefetch
73
NUS.SOC.CS5248 OOI WEI TSANG 73 Prefetch Algorithm prefetch window playback point
74
NUS.SOC.CS5248 OOI WEI TSANG 74 Proxy Request to Server Multiple requests (for different clients) are batched.
75
NUS.SOC.CS5248 OOI WEI TSANG 75 Server Response Missing segments are sent in decreasing priority 1 2 34
76
NUS.SOC.CS5248 OOI WEI TSANG 76 Server Response Send as many segments as possible until next prefetch request
77
NUS.SOC.CS5248 OOI WEI TSANG 77 Solutions Making cache “quality-aware” Prefetch Replacement Algorithm
78
NUS.SOC.CS5248 OOI WEI TSANG 78 Goal of Replacement Algorithm Goal: converge to efficient state if a stream is popular average quality is high variation in quality is low
79
NUS.SOC.CS5248 OOI WEI TSANG 79 The Algorithm
80
NUS.SOC.CS5248 OOI WEI TSANG 80 Trashing and Locking
81
NUS.SOC.CS5248 OOI WEI TSANG 81 Choosing Victim whit (weighted hit) = T play /T total Calculate whit for each layer in a stream over a popularity window
82
NUS.SOC.CS5248 OOI WEI TSANG 82 Example PopularityLock?NameLayer 5.91Nemo0 4.31Nemo1 4.00Matrix 20 3.90Matrix 21 1.10Gigli0
83
NUS.SOC.CS5248 OOI WEI TSANG 83 Evaluations Two Criteria Completeness Continuity
84
NUS.SOC.CS5248 OOI WEI TSANG 84 vs Request Number
85
NUS.SOC.CS5248 OOI WEI TSANG 85 Different Popularity
86
NUS.SOC.CS5248 OOI WEI TSANG 86 Summary Proxy Caching for video Techniques for segmentation, replacement etc. Interactions with other aspect of streaming
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.