DHTs and Sharding Aurojit Panda Announcements Announcements Fill - - PowerPoint PPT Presentation

dhts and sharding
SMART_READER_LITE
LIVE PREVIEW

DHTs and Sharding Aurojit Panda Announcements Announcements Fill - - PowerPoint PPT Presentation

DHTs and Sharding Aurojit Panda Announcements Announcements Fill out the Github consent form. Announcements Fill out the Github consent form. Fill out the Github account association form. Announcements Fill out the Github


slide-1
SLIDE 1

DHTs and Sharding

Aurojit Panda

slide-2
SLIDE 2

Announcements

slide-3
SLIDE 3

Announcements

  • Fill out the Github consent form.
slide-4
SLIDE 4

Announcements

  • Fill out the Github consent form.
  • Fill out the Github account association form.
slide-5
SLIDE 5

Announcements

  • Fill out the Github consent form.
  • Fill out the Github account association form.
  • Lab 0 is due tonight. Hopefully all of you are done.
slide-6
SLIDE 6

Announcements

  • Fill out the Github consent form.
  • Fill out the Github account association form.
  • Lab 0 is due tonight. Hopefully all of you are done.
  • Contacting me: please send e-mail to apanda@cs.nyu.edu
slide-7
SLIDE 7

Announcements

  • Fill out the Github consent form.
  • Fill out the Github account association form.
  • Lab 0 is due tonight. Hopefully all of you are done.
  • Contacting me: please send e-mail to apanda@cs.nyu.edu
  • I do not check the main NYU e-mail address all that often.
slide-8
SLIDE 8

Clarifying Final Project

  • Some concern about how projects will be graded.
slide-9
SLIDE 9

Clarifying Final Project

  • Some concern about how projects will be graded.
  • Not really looking to be adversarial: ideal outcome is everyone gets an A.
slide-10
SLIDE 10

Clarifying Final Project

  • Some concern about how projects will be graded.
  • Not really looking to be adversarial: ideal outcome is everyone gets an A.
  • Main bar: write a proposal that we both agree on.
slide-11
SLIDE 11

Clarifying Final Project

  • Some concern about how projects will be graded.
  • Not really looking to be adversarial: ideal outcome is everyone gets an A.
  • Main bar: write a proposal that we both agree on.
  • Important to scope it so that you have some chance of finishing things.
slide-12
SLIDE 12

Clarifying Final Project

  • Some concern about how projects will be graded.
  • Not really looking to be adversarial: ideal outcome is everyone gets an A.
  • Main bar: write a proposal that we both agree on.
  • Important to scope it so that you have some chance of finishing things.
  • Important to include something you would enjoy working on.
slide-13
SLIDE 13

Clarifying Final Project

  • Some concern about how projects will be graded.
  • Not really looking to be adversarial: ideal outcome is everyone gets an A.
  • Main bar: write a proposal that we both agree on.
  • Important to scope it so that you have some chance of finishing things.
  • Important to include something you would enjoy working on.
  • Beyond that main metric is whether you put in the effort.
slide-14
SLIDE 14

Clarifying Final Project

  • Some concern about how projects will be graded.
  • Not really looking to be adversarial: ideal outcome is everyone gets an A.
  • Main bar: write a proposal that we both agree on.
  • Important to scope it so that you have some chance of finishing things.
  • Important to include something you would enjoy working on.
  • Beyond that main metric is whether you put in the effort.
  • Expect that many projects won't be done in time. That is fine.
slide-15
SLIDE 15

Clarifying Final Project

  • Some concern about how projects will be graded.
  • Not really looking to be adversarial: ideal outcome is everyone gets an A.
  • Main bar: write a proposal that we both agree on.
  • Important to scope it so that you have some chance of finishing things.
  • Important to include something you would enjoy working on.
  • Beyond that main metric is whether you put in the effort.
  • Expect that many projects won't be done in time. That is fine.
  • Some ideas will fail to bear out. That is also fine.
slide-16
SLIDE 16

Some Comments on Summaries

  • Thanks for sending summaries, looked over most of them.
slide-17
SLIDE 17

Some Comments on Summaries

  • Thanks for sending summaries, looked over most of them.
  • A few observations about mechanics:
slide-18
SLIDE 18

Some Comments on Summaries

  • Thanks for sending summaries, looked over most of them.
  • A few observations about mechanics:
  • Please use the subject and e-mail address on the website.
slide-19
SLIDE 19

Some Comments on Summaries

  • Thanks for sending summaries, looked over most of them.
  • A few observations about mechanics:
  • Please use the subject and e-mail address on the website.
  • Please write your summary in the body of the e-mail, do not send t.
slide-20
SLIDE 20

Some Comments on Summaries

  • Thanks for sending summaries, looked over most of them.
  • A few observations about mechanics:
  • Please use the subject and e-mail address on the website.
  • Please write your summary in the body of the e-mail, do not send t.
  • A few observations about content:
slide-21
SLIDE 21

Some Comments on Summaries

  • Thanks for sending summaries, looked over most of them.
  • A few observations about mechanics:
  • Please use the subject and e-mail address on the website.
  • Please write your summary in the body of the e-mail, do not send t.
  • A few observations about content:
  • Sorry about Slicer, it was not as self-contained as I thought it would be.
slide-22
SLIDE 22

Some Comments on Summaries

  • Thanks for sending summaries, looked over most of them.
  • A few observations about mechanics:
  • Please use the subject and e-mail address on the website.
  • Please write your summary in the body of the e-mail, do not send t.
  • A few observations about content:
  • Sorry about Slicer, it was not as self-contained as I thought it would be.
  • Would have liked to see a little more on how the papers relate to each other.
slide-23
SLIDE 23

Office Hour Etiquette

  • Sorry, I know this sounds bad for you, but necessary for my sanity.
slide-24
SLIDE 24

Office Hour Etiquette

  • Sorry, I know this sounds bad for you, but necessary for my sanity.
  • My office hours are on Thursday from 5 - 6PM or by appointment.
slide-25
SLIDE 25

Office Hour Etiquette

  • Sorry, I know this sounds bad for you, but necessary for my sanity.
  • My office hours are on Thursday from 5 - 6PM or by appointment.
  • Please don't come to my office for class help outside of these circumstances.
slide-26
SLIDE 26

Office Hour Etiquette

  • Sorry, I know this sounds bad for you, but necessary for my sanity.
  • My office hours are on Thursday from 5 - 6PM or by appointment.
  • Please don't come to my office for class help outside of these circumstances.
  • Fine to come for other things like:
slide-27
SLIDE 27

Office Hour Etiquette

  • Sorry, I know this sounds bad for you, but necessary for my sanity.
  • My office hours are on Thursday from 5 - 6PM or by appointment.
  • Please don't come to my office for class help outside of these circumstances.
  • Fine to come for other things like:
  • Research or advice about random things.
slide-28
SLIDE 28

Office Hour Etiquette

  • Sorry, I know this sounds bad for you, but necessary for my sanity.
  • My office hours are on Thursday from 5 - 6PM or by appointment.
  • Please don't come to my office for class help outside of these circumstances.
  • Fine to come for other things like:
  • Research or advice about random things.
  • Informing me about new/better ice cream places.
slide-29
SLIDE 29

Now onto more fun stuff

slide-30
SLIDE 30

Two Problems - One Solution?

  • Distributed data storage and management.
  • Load distribution.
slide-31
SLIDE 31

Two Problems - One Solution?

  • Distributed data storage and management.
  • Load distribution.
slide-32
SLIDE 32

DHTs

slide-33
SLIDE 33

Some History

  • 1999: Shawn Fanning and Sean Parker create Napster
slide-34
SLIDE 34

Some History

  • 1999: Shawn Fanning and Sean Parker create Napster
  • 2000: Metallica + RIAA + other sue Napster.
slide-35
SLIDE 35

Some History

  • 1999: Shawn Fanning and Sean Parker create Napster
  • 2000: Metallica + RIAA + other sue Napster.
  • 2001: Napster shuts down network due to injunction.
slide-36
SLIDE 36

Some History

  • 1999: Shawn Fanning and Sean Parker create Napster
  • 2000: Metallica + RIAA + other sue Napster.
  • 2001: Napster shuts down network due to injunction.
  • What? Why?
slide-37
SLIDE 37

Napster: Original Design

Yogi Huckelberry Snuffles Penelope Track 1 Track 2 Track 1: Snuffles Track 2: Penelope

slide-38
SLIDE 38

Napster: Original Design

Yogi Huckelberry Snuffles Penelope Track 1 Track 2 Track 1: Snuffles Track 2: Penelope

slide-39
SLIDE 39

Napster: Original Design

Yogi Huckelberry Snuffles Penelope Track 1 Track 2

slide-40
SLIDE 40

Centralization affects Survivability

  • Easier to shutdown infrastructure.
slide-41
SLIDE 41

Centralization affects Survivability

  • Easier to shutdown infrastructure.
  • Infrastructure is more susceptible to failure.
slide-42
SLIDE 42

Centralization affects Survivability

  • Easier to shutdown infrastructure.
  • Infrastructure is more susceptible to failure.
  • But also much easier to build and manage.
slide-43
SLIDE 43

An Alternative to Centralization

Yogi Huckelberry Snuffles Penelope Track 1 Track 2 ... ... ... ... ...

slide-44
SLIDE 44

An Alternative to Centralization

Yogi Huckelberry Snuffles Penelope Track 1 Track 2 ... ... ... ... ...

Any problems with this approach?

slide-45
SLIDE 45

Distributed Hash Tables

  • Rather than replicating data, distribute it across nodes.
  • Requirements:
  • Allow lookup without requiring a centralized index.
  • Allow nodes to enter and exit with relative ease.
  • Several proposals: Chord, CAN, Kadmelia, ...
  • Several in use: Kadmelia used for the BitTorrent trackers.
slide-46
SLIDE 46

Chord

slide-47
SLIDE 47

Consistent Hashing

  • Consider a hash table with b buckets and n items.
slide-48
SLIDE 48

Consistent Hashing

  • Consider a hash table with b buckets and n items.
  • Add a new bucket, so there are now b + 1 buckets.
slide-49
SLIDE 49

Consistent Hashing

  • Consider a hash table with b buckets and n items.
  • Add a new bucket, so there are now b + 1 buckets.
  • How many items need to move?
slide-50
SLIDE 50

Consistent Hashing

  • Depends on what hashing algorithm you use.
  • But one pretty common strategy (with some additional details missing)

h: 16 buckets

slide-51
SLIDE 51

Consistent Hashing

  • Depends on what hashing algorithm you use.
  • But one pretty common strategy (with some additional details missing)

h: h[k] = v 16 buckets

slide-52
SLIDE 52

Consistent Hashing

  • Depends on what hashing algorithm you use.
  • But one pretty common strategy (with some additional details missing)

h: h[k] = v 16 buckets h[hash(k) % len(h)] = v

slide-53
SLIDE 53

Consistent Hashing

  • Depends on what hashing algorithm you use.
  • But one pretty common strategy (with some additional details missing)

h: h[k] = v 16 buckets h[hash(k) % len(h)] = v h[hash(k) % 16] = v

slide-54
SLIDE 54

Consistent Hashing

  • Depends on what hashing algorithm you use.
  • But one pretty common strategy (with some additional details missing)

h: h[k] = v 16 buckets h[hash(k) % len(h)] = v h[hash(k) % 16] = v

v

slide-55
SLIDE 55

Consistent Hashing

h: h[k] = v 16 buckets h[hash(k) % len(h)] = v h[hash(k) % 16] = v x = h[k]

v

slide-56
SLIDE 56

Consistent Hashing

h: h[k] = v 16 buckets h[hash(k) % len(h)] = v h[hash(k) % 16] = v x = h[k] x = h[hash(k) % len(h)]

v

slide-57
SLIDE 57

Consistent Hashing

h: h[k] = v 16 buckets h[hash(k) % len(h)] = v h[hash(k) % 16] = v x = h[k] x = h[hash(k) % len(h)] x = h[hash(k) % 16]

v

slide-58
SLIDE 58

Consistent Hashing

h: 20 buckets x = h[k] x = h[hash(k) % len(h)] x = h[hash(k) % 16] Added 4 buckets x = h[k] x = h[hash(k) % len(h)] x = h[hash(k) % 20]

v

slide-59
SLIDE 59

Consistent Hashing

h: 20 buckets x = h[k] x = h[hash(k) % len(h)] x = h[hash(k) % 16] Added 4 buckets x = h[k] x = h[hash(k) % len(h)] x = h[hash(k) % 20]

v

How many items need to move?

slide-60
SLIDE 60

Consistent Hashing

  • David Karger, et al. 1997 at MIT: Mechanism to minimize reassignments.
slide-61
SLIDE 61

Consistent Hashing

  • David Karger, et al. 1997 at MIT: Mechanism to minimize reassignments.
  • Monotonicity: When buckets are added items move from old to new.
slide-62
SLIDE 62

Consistent Hashing

  • David Karger, et al. 1997 at MIT: Mechanism to minimize reassignments.
  • Monotonicity: When buckets are added items move from old to new.
  • No items move between old buckets.
slide-63
SLIDE 63

Consistent Hashing

  • David Karger, et al. 1997 at MIT: Mechanism to minimize reassignments.
  • Monotonicity: When buckets are added items move from old to new.
  • No items move between old buckets.
  • Also require other properties (e.g., balance) which are more traditional.
slide-64
SLIDE 64

Consistent Hashing

slide-65
SLIDE 65

Consistent Hashing

  • Map each bucket to a point in the unit interval.
slide-66
SLIDE 66

Consistent Hashing

  • Map each bucket to a point in the unit interval.
  • How? Use a hash function hb.
slide-67
SLIDE 67

Consistent Hashing

  • Map each bucket to a point in the unit interval.
  • How? Use a hash function hb.
  • Map each key to a point in the unit interval.
slide-68
SLIDE 68

Consistent Hashing

  • Map each bucket to a point in the unit interval.
  • How? Use a hash function hb.
  • Map each key to a point in the unit interval.
  • How? Use another hash function hk.
slide-69
SLIDE 69

Consistent Hashing

  • Map each bucket to a point in the unit interval.
  • How? Use a hash function hb.
  • Map each key to a point in the unit interval.
  • How? Use another hash function hk.
  • Map key k to bucket b such that: |hk(k) - hb(b)| is minimal.
slide-70
SLIDE 70

Consistent Hashing

  • Map each bucket to a point in the unit interval.
  • How? Use a hash function hb.
  • Map each key to a point in the unit interval.
  • How? Use another hash function hk.
  • Map key k to bucket b such that: |hk(k) - hb(b)| is minimal.
  • Is this sufficient for monotonicity?
slide-71
SLIDE 71

Chord

  • Use consistent hashing to build a distributed hash table.
  • Keys must be allocated across different nodes.
  • Balanced, i.e., no more than (1 + ε)K/N keys go to a single node.
  • Minimize amount of data that needs to be synchronized.
  • Especially important when nodes leave or join.
slide-72
SLIDE 72

Chord Slow Lookup

2 35 1

Successor pointer

slide-73
SLIDE 73

Chord Slow Lookup

2 35 1

Successor pointer lookup(k) hash(k) = 7

slide-74
SLIDE 74

Chord Slow Lookup

2 35 1

Successor pointer lookup(k) hash(k) = 7

slide-75
SLIDE 75

Chord Join

2 35 1

Successor pointer 2: ... 3: ... 4: ... 27: ... 37: ... 42: ... 0: ...

slide-76
SLIDE 76

Chord Join

2 35 1

Successor pointer

8

2: ... 3: ... 4: ... 27: ... 37: ... 42: ... 0: ...

slide-77
SLIDE 77

Chord Join

2 35 1

Successor pointer

8

2: ... 3: ... 4: ... 27: ... 37: ... 42: ... 0: ... Predecessor pointer

slide-78
SLIDE 78

Chord Join

2 35 1

Successor pointer

8

2: ... 3: ... 4: ... 27: ... 37: ... 42: ... 0: ... Predecessor pointer

slide-79
SLIDE 79

Chord Join

2 35 1

Successor pointer

8

2: ... 27: ... 37: ... 42: ... 0: ... Predecessor pointer 3: ... 4: ...

slide-80
SLIDE 80

Chord Leave

2 35 1

Successor pointer

8

2: ... 27: ... 37: ... 42: ... 0: ... Predecessor pointer 3: ... 4: ...

slide-81
SLIDE 81

Chord Leave

2 35 1

Successor pointer 2: ... 27: ... 37: ... 42: ... 0: ... Predecessor pointer

slide-82
SLIDE 82

Chord Leave

2 35 1

Successor pointer 2: ... 27: ... 37: ... 42: ... 0: ... Predecessor pointer Oops: Need successor list to fix this problem

slide-83
SLIDE 83

Chord Leave

2 35 1

Successor pointer 2: ... 27: ... 37: ... 42: ... 0: ... Predecessor pointer

slide-84
SLIDE 84

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

slide-85
SLIDE 85

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

slide-86
SLIDE 86

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

finger[k] = succ(n + 2k−1) mod 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LIDE 87

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

finger[k] = succ(n + 2k−1) mod 2m)

<latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit><latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3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COLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit>

Finger

slide-88
SLIDE 88

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

finger[k] = succ(n + 2k−1) mod 2m)

<latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit><latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHA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gZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit>

Finger

1

slide-89
SLIDE 89

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

finger[k] = succ(n + 2k−1) mod 2m)

<latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit><latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq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+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit>

Finger

1 2

slide-90
SLIDE 90

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

finger[k] = succ(n + 2k−1) mod 2m)

<latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit><latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8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V/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit>

Finger

1 2 3

slide-91
SLIDE 91

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

finger[k] = succ(n + 2k−1) mod 2m)

<latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</lat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sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit>

Finger

1 2 3 4

slide-92
SLIDE 92

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

finger[k] = succ(n + 2k−1) mod 2m)

<latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7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Rdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit><latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit>

Finger

1 2 3 4 5

slide-93
SLIDE 93

Fingers

2 3 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 38

3.lookup(k) hash(k) = 42 m=6 (2m = 64)

finger[k] = succ(n + 2k−1) mod 2m)

<latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/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U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit><latexit sha1_base64="o0lJPfhPEwESip2b8DuHRmlkxGM=">ACHnicbVDLSgMxFM34tr6qLt0Ei6CIZUYU3QiG5cKVoV2LJn0Tg1NMkNyRyzDfIkbf8WNC0UEV/o3po+FrwMXTs65l9x7olQKi7/6Y2Mjo1PTE5Nl2Zm5+YXyotLFzbJDIcaT2RiriJmQoNRQo4So1wFQk4TLqHPf8y1swViT6HLsphIq1tYgFZ+ikZnm3gXCHeSx0G0xR74T0gA4km3FerGu6Sbev85WUGzQhkpa7qU2muWKX/X7oH9JMCQVMsRps/zeaCU8U6CRS2ZtPfBTDHNmUHAJRamRWUgZ7A21B3VTIEN8/5BV1zSovGiXGlkfbV7xM5U9Z2VeQ6FcMb+9vrif959Qzj/TAXOs0QNB98FGeSYkJ7WdGWMBRdh1h3Ai3K+U3zDCOLtGSCyH4fJfcrFdDfxqcLZTOTwaxjFVsgqWScB2SOH5ISckhrh5J48kmfy4j14T96r9zZoHfGM8vkB7yPLztQoTU=</latexit>

Finger

1 2 3 4 5 6

slide-94
SLIDE 94

Some Concerns

  • What happens with simultaneous joins and leaves?
  • Can you ever loose track of a node?
  • Can you ever get to a state where a node joins and then disappears?
slide-95
SLIDE 95

An aside on hashing

  • Why SHA-1/SHA-256/...?
slide-96
SLIDE 96

An aside on hashing

  • Why SHA-1/SHA-256/...?
  • Do we need cryptographic hash functions for this purpose?
slide-97
SLIDE 97

An aside on hashing

  • Why SHA-1/SHA-256/...?
  • Do we need cryptographic hash functions for this purpose?
  • There are other hash functions that are much faster to compute.
slide-98
SLIDE 98

An aside on hashing

  • Why SHA-1/SHA-256/...?
  • Do we need cryptographic hash functions for this purpose?
  • There are other hash functions that are much faster to compute.
  • Why are cryptographic hash functions well suited to this purpose?
slide-99
SLIDE 99

Two Problems - One Solution?

  • Distributed data storage and management.
  • Load distribution.
slide-100
SLIDE 100

Sharding and Load Balancing

slide-101
SLIDE 101

Why Shard?

  • Services like databases rely on several resources.
slide-102
SLIDE 102

Why Shard?

  • Services like databases rely on several resources.
  • Storage (to persist), memory (to cache), CPU (to compute), etc.
slide-103
SLIDE 103

Why Shard?

  • Services like databases rely on several resources.
  • Storage (to persist), memory (to cache), CPU (to compute), etc.
  • An individual node might not have sufficient resources to handle load.
slide-104
SLIDE 104

Why Shard?

  • Services like databases rely on several resources.
  • Storage (to persist), memory (to cache), CPU (to compute), etc.
  • An individual node might not have sufficient resources to handle load.
  • For example, the database might be too big to fit on one server.
slide-105
SLIDE 105

Why Shard?

  • Services like databases rely on several resources.
  • Storage (to persist), memory (to cache), CPU (to compute), etc.
  • An individual node might not have sufficient resources to handle load.
  • For example, the database might be too big to fit on one server.
  • For example, many updates to a single row mean not enough CPU for all.
slide-106
SLIDE 106

Why Shard?

  • Services like databases rely on several resources.
  • Storage (to persist), memory (to cache), CPU (to compute), etc.
  • An individual node might not have sufficient resources to handle load.
  • For example, the database might be too big to fit on one server.
  • For example, many updates to a single row mean not enough CPU for all.
  • Sharding is one way to spread the load around.
slide-107
SLIDE 107

Load Balancing

  • Sometimes one cannot partition the data, and instead must replicate it.
slide-108
SLIDE 108

Load Balancing

  • Sometimes one cannot partition the data, and instead must replicate it.
  • Also provides resilience: no replication no data after failure.
slide-109
SLIDE 109

Load Balancing

  • Sometimes one cannot partition the data, and instead must replicate it.
  • Also provides resilience: no replication no data after failure.
  • Load balancing decides who serves any given request.
slide-110
SLIDE 110

Load Balancing

  • Sometimes one cannot partition the data, and instead must replicate it.
  • Also provides resilience: no replication no data after failure.
  • Load balancing decides who serves any given request.
  • Who scales the load balancer?
slide-111
SLIDE 111

Load Balancing

  • Sometimes one cannot partition the data, and instead must replicate it.
  • Also provides resilience: no replication no data after failure.
  • Load balancing decides who serves any given request.
  • Who scales the load balancer?
  • Interesting question but won't think about this today.
slide-112
SLIDE 112

Both Problems are Somewhat Related

slide-113
SLIDE 113

Both Problems are Somewhat Related

  • Where should a request be routed?
slide-114
SLIDE 114

Both Problems are Somewhat Related

  • Where should a request be routed?
  • Where should something be stored?
slide-115
SLIDE 115

Some Useful Properties

  • Related data stays together/related requests get routed to the same machine.

x = 1 x = 1

slide-116
SLIDE 116

Some Useful Properties

  • Related data stays together/related requests get routed to the same machine.

x = 1 x = 1 set x = 2

slide-117
SLIDE 117

Some Useful Properties

  • Related data stays together/related requests get routed to the same machine.

x = 2 x = 1 set x = 2 set x = 2

slide-118
SLIDE 118

Some Useful Properties

  • Related data stays together/related requests get routed to the same machine.

x = 2 x = 1 set x = 2 get x set x = 2

slide-119
SLIDE 119

Some Useful Properties

  • Related data stays together/related requests get routed to the same machine.

x = 2 x = 1 set x = 2 set x = 2

slide-120
SLIDE 120

Some Useful Properties

  • Related data stays together/related requests get routed to the same machine.

x = 2 x = 1 set x = 2 get x set x = 2

slide-121
SLIDE 121

Some Useful Properties

  • Related data stays together/related requests get routed to the same machine.

x = 2 x = 1 set x = 2 get x set x = 2 When are requests/data related?

slide-122
SLIDE 122

Some Useful Properties

  • Ability to add more capacity without disruption.

x = 1 x = 1

slide-123
SLIDE 123

How can we do this?

slide-124
SLIDE 124

Sometimes Consistent Hashing is Not Enough

  • Consistent hashing works to give the previous two properties.
slide-125
SLIDE 125

Sometimes Consistent Hashing is Not Enough

  • Consistent hashing works to give the previous two properties.
  • Bigger problem is that a single data unit, or request might be more popular.
slide-126
SLIDE 126

Sometimes Consistent Hashing is Not Enough

  • Consistent hashing works to give the previous two properties.
  • Bigger problem is that a single data unit, or request might be more popular.
  • Common observance for web workloads.
slide-127
SLIDE 127

Sometimes Consistent Hashing is Not Enough

  • Consistent hashing works to give the previous two properties.
  • Bigger problem is that a single data unit, or request might be more popular.
  • Common observance for web workloads.
  • Random hashing is insufficient for this.
slide-128
SLIDE 128

Sometimes Consistent Hashing is Not Enough

  • Consistent hashing works to give the previous two properties.
  • Bigger problem is that a single data unit, or request might be more popular.
  • Common observance for web workloads.
  • Random hashing is insufficient for this.
  • Very little control over what ends up loaded.
slide-129
SLIDE 129

Sometimes Consistent Hashing is Not Enough

  • Consistent hashing works to give the previous two properties.
  • Bigger problem is that a single data unit, or request might be more popular.
  • Common observance for web workloads.
  • Random hashing is insufficient for this.
  • Very little control over what ends up loaded.
  • Too hard to reverse engineer an appropriate hash function.
slide-130
SLIDE 130

Slicer Like Solutions

  • Retain some structures from consistent hashing.
slide-131
SLIDE 131

Slicer Like Solutions

  • Retain some structures from consistent hashing.
  • Map keys to ranges in some interval.
slide-132
SLIDE 132

Slicer Like Solutions

  • Retain some structures from consistent hashing.
  • Map keys to ranges in some interval.
  • Assign key ranges to individual nodes.
slide-133
SLIDE 133

Slicer Like Solutions

  • Retain some structures from consistent hashing.
  • Map keys to ranges in some interval.
  • Assign key ranges to individual nodes.
  • Respond to different scenarios by
slide-134
SLIDE 134

Slicer Like Solutions

  • Retain some structures from consistent hashing.
  • Map keys to ranges in some interval.
  • Assign key ranges to individual nodes.
  • Respond to different scenarios by
  • Merging adjacent ranges.
slide-135
SLIDE 135

Slicer Like Solutions

  • Retain some structures from consistent hashing.
  • Map keys to ranges in some interval.
  • Assign key ranges to individual nodes.
  • Respond to different scenarios by
  • Merging adjacent ranges.
  • Partitioning ranges.
slide-136
SLIDE 136

A Few Challenges

  • Assigning a key to a partition is no longer stateless.
  • Need to record this information somewhere.
  • Need to make sure that you can safely update this configuration.
  • Despite multiple assigners which might fail or arrive at inopportune moments.
  • Despite arbitrary delays.
  • One of the things the paper addresses using CAS in Section 4.1.
slide-137
SLIDE 137

Conclusion

  • Problem: How to spread request/data/... across machines.
  • Rather how to ensure that everyone agrees on what machine to go to.
  • Elegant solution: Do it with hashing, no state.
  • Elegant but some limits on what can be achieved.
  • General solution: Rely on state, enforce any policy on how things are spread.
  • Now you have two problems: how to distribute and keep state in sync?