Towards Efficient Stream Processing in the Wide Area - - PowerPoint PPT Presentation

towards efficient stream processing in the wide area
SMART_READER_LITE
LIVE PREVIEW

Towards Efficient Stream Processing in the Wide Area - - PowerPoint PPT Presentation

Towards Efficient Stream Processing in the Wide Area Matvey Arye Siddhartha Sen, Ariel Rabkin, Michael J. Freedman Princeton University Our


slide-1
SLIDE 1

Towards ¡Efficient ¡Stream ¡ Processing ¡in ¡the ¡Wide ¡Area ¡

Matvey ¡Arye ¡

¡Siddhartha ¡Sen, ¡Ariel ¡Rabkin, ¡ ¡

Michael ¡J. ¡Freedman ¡ ¡

¡ ¡

Princeton ¡University ¡

slide-2
SLIDE 2

Our ¡Problem ¡Domain ¡

slide-3
SLIDE 3

Also ¡Our ¡Problem ¡Domain ¡

slide-4
SLIDE 4

Use ¡Cases ¡

  • Network ¡Monitoring ¡
  • Internet ¡Service ¡Monitoring ¡
  • Military ¡Intelligence ¡
  • Smart ¡Grid ¡
  • Environmental ¡Sensing ¡
  • Internet ¡of ¡Things ¡

¡

slide-5
SLIDE 5

The ¡World ¡of ¡AnalyKcal ¡Processing ¡

Real-­‑Time ¡ Historical ¡

Streaming ¡ OLAP ¡Databases ¡

slide-6
SLIDE 6

The ¡World ¡of ¡AnalyKcal ¡Processing ¡

Real-­‑Time ¡ Historical ¡

Streaming ¡ OLAP ¡Databases ¡

Simpler ¡queries ¡ Standing ¡queries ¡ Real-­‑Kme ¡answers ¡ ¡ Borealis/Streambase ¡ System-­‑S, ¡Storm ¡ High ¡ingest ¡Kme ¡ Fast ¡query ¡Kme ¡ ¡ ¡ Oracle, ¡SAP, ¡IBM ¡

Single ¡ Datacenter ¡

slide-7
SLIDE 7

Data ¡Transfer ¡

slide-8
SLIDE 8

[Above ¡the ¡Clouds, ¡Armbrust ¡et. ¡al.] ¡ ¡

Trends ¡in ¡Cost/Performance ¡ 2003-­‑2008 ¡

CPU(16x) ¡ Storage(10x) ¡ Bandwidth(2.7x) ¡

slide-9
SLIDE 9

Aggregate ¡At ¡Local ¡Datacenters ¡

slide-10
SLIDE 10

The ¡World ¡of ¡AnalyKcal ¡Processing ¡

Real-­‑Time ¡ Historical ¡

Streaming ¡ OLAP ¡ Databases ¡

Single ¡ Datacenter ¡ Wide ¡area ¡

JetStream ¡

JetStream ¡= ¡Real-­‑Kme ¡+ ¡Historical ¡+ ¡Wide ¡Area ¡ ¡

slide-11
SLIDE 11

Large ¡Caveat ¡

¡

  • Preliminary ¡work ¡
  • We ¡want ¡feedback ¡

and ¡suggesKons ¡

slide-12
SLIDE 12

Challenges ¡

  • Query ¡placement ¡and ¡scheduling ¡
  • ApproximaKon ¡of ¡answers ¡
  • SupporKng ¡User ¡Defined ¡FuncKons ¡(UDFs) ¡
  • Queries ¡on ¡historical ¡data ¡
  • AdaptaKon ¡to ¡network ¡changes ¡
  • Handling ¡node ¡failures ¡
slide-13
SLIDE 13

MoKvaKng ¡Example ¡

  • “Top-­‑K ¡domains ¡served ¡by ¡a ¡CDN” ¡

– Recall ¡CDN ¡is ¡globally ¡distributed ¡ – Services ¡many ¡domains ¡

¡

  • Main ¡Challenge: ¡Minimize ¡backhaul ¡of ¡data ¡
slide-14
SLIDE 14

How ¡Is ¡the ¡Query ¡Specified ¡ ¡

Union ¡ Count ¡ Sort ¡ Limit ¡

slide-15
SLIDE 15

Problems ¡

Single ¡aggregaKon ¡point ¡ Runs ¡on ¡a ¡single ¡node ¡

Union ¡ Count ¡ Sort ¡ Limit ¡

slide-16
SLIDE 16

DC3 ¡

¡ ¡ ¡

DC1 ¡ ¡ ¡ ¡

Aggregate ¡at ¡local ¡DC ¡ ¡

Count ¡ ParKal ¡

DC2 ¡ ¡ ¡ ¡

Count ¡ ParKal ¡

Less ¡Data ¡

Union ¡ Count ¡ Sort ¡ Limit ¡

slide-17
SLIDE 17

Count ¡ParKals ¡

Count ¡ ParKal ¡ Union ¡ Count ¡

( G

  • g

l e , 1 ) ¡ (Google,1) ¡ (Google,1) ¡ ( G

  • g

l e , 1 ) ¡ (Google,5) ¡

slide-18
SLIDE 18

DC3 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡

Non-­‑Distributed ¡ComputaKon ¡

DC1 ¡ ¡ DC2 ¡ ¡

Union ¡ Count ¡ Sort ¡ Limit ¡

slide-19
SLIDE 19

DC3 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡

Split ¡Count ¡

DC1 ¡ ¡ DC2 ¡ ¡

Union ¡ Sort ¡ Limit ¡ Count ¡ A-­‑H ¡ Count ¡ I-­‑M ¡ Count ¡ N-­‑Z ¡

slide-20
SLIDE 20

DC3 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡

Split ¡Union ¡

DC1 ¡ ¡ DC2 ¡ ¡

Sort ¡ Limit ¡ Count ¡ A-­‑H ¡ Count ¡ I-­‑M ¡ Count ¡ N-­‑Z ¡ Load ¡

  • Bal. ¡

Load ¡

  • Bal. ¡
slide-21
SLIDE 21

DC3 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡

Do ¡ParKal ¡Sort ¡

DC1 ¡ ¡ DC2 ¡ ¡

Sort ¡ Limit ¡ Count ¡ A-­‑H ¡ Count ¡ I-­‑M ¡ Count ¡ N-­‑Z ¡ Load ¡

  • Bal. ¡

Load ¡

  • Bal. ¡

Sort ¡ ParKal ¡ Sort ¡ ParKal ¡ Sort ¡ ParKal ¡

slide-22
SLIDE 22

DC3 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡

Push ¡Limit ¡Back ¡

Load ¡

  • Bal. ¡

Count ¡ A-­‑H ¡ Sort ¡ ParKal ¡ Limit ¡ Count ¡ I-­‑M ¡ Count ¡ N-­‑Z ¡ Load ¡

  • Bal. ¡

Sort ¡ Limit ¡

DC1 ¡ ¡ DC2 ¡ ¡

Sort ¡ ParKal ¡ Sort ¡ ParKal ¡ Limit ¡ Limit ¡

slide-23
SLIDE 23

DC3 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡

Single ¡Host ¡

Distributed ¡Version ¡

Load ¡

  • Bal. ¡

Count ¡ A-­‑H ¡ Sort ¡ ParKal ¡ Limit ¡ Count ¡ I-­‑M ¡ Count ¡ N-­‑Z ¡ Load ¡

  • Bal. ¡

Sort ¡ Limit ¡

DC1 ¡ ¡ DC2 ¡ ¡

Sort ¡ ParKal ¡ Sort ¡ ParKal ¡ Limit ¡ Limit ¡

slide-24
SLIDE 24

What ¡Is ¡New ¡

  • Previous ¡streaming ¡systems ¡ ¡

– User ¡guided ¡transformaKons ¡(System-­‑S, ¡Storm) ¡ – Simple ¡transforms ¡(Aurora) ¡ ¡

  • JetStream ¡

– More ¡complex ¡transforms ¡ ¡ – TransformaKon ¡is ¡network ¡aware ¡ – AnnotaKons ¡for ¡user ¡defined ¡funcKons ¡

slide-25
SLIDE 25

Joint ¡Problems ¡

  • TransformaKons ¡

– Choosing ¡which ¡ones ¡

  • Placement ¡

– Network ¡constrained ¡ – Heterogeneous ¡nodes ¡ – Resource ¡availability ¡

  • Decision ¡has ¡to ¡be ¡made ¡at ¡run-­‑Kme ¡
slide-26
SLIDE 26

Tackling ¡the ¡Joint ¡Problems ¡

  • Using ¡heurisKcs ¡
  • Split ¡into ¡increasingly ¡more ¡local ¡decisions ¡

– Global ¡decisions ¡are ¡coarse ¡grained ¡

  • Example: ¡Assign ¡operators ¡to ¡DCs ¡ ¡

– Localized ¡decisions ¡

  • Operate ¡only ¡on ¡local ¡part ¡of ¡subgraph ¡
  • Have ¡more ¡current ¡view ¡of ¡available ¡resources ¡
  • Do ¡not ¡affect ¡other ¡parts ¡of ¡of ¡query ¡graph ¡placement ¡
slide-27
SLIDE 27

DC3 ¡

¡ ¡ ¡

DC1 ¡ ¡ ¡ ¡

Bollenecks ¡SKll ¡Possible ¡

Count ¡ ParKal ¡

DC2 ¡ ¡ ¡ ¡

Count ¡ ParKal ¡

Possible ¡Bolleneck ¡

Union ¡ Count ¡ Sort ¡ Limit ¡

Use ¡ApproximaKons ¡when ¡necessary ¡

slide-28
SLIDE 28

DC3 ¡

¡ ¡ ¡

DC1 ¡ ¡ ¡ ¡

AdjusKng ¡Amount ¡of ¡ApproximaKon ¡

As ¡a ¡reacKon ¡to ¡network ¡dynamism ¡ ¡

Count ¡ ParKal ¡

DC2 ¡ ¡ ¡ ¡

Count ¡ ParKal ¡

If ¡bolleneck ¡goes ¡away, ¡return ¡to ¡exact ¡answers ¡

Union ¡ Count ¡ Sort ¡ Limit ¡

slide-29
SLIDE 29

ApproximaKon ¡Challenges ¡

  • How ¡to ¡quanKfy ¡error ¡for ¡approximaKons? ¡

– Uniform ¡across ¡approximaKon ¡methods ¡ – Easy ¡to ¡understand ¡ – Integrates ¡well ¡with ¡metrics ¡for ¡source/node ¡failures ¡

  • How ¡do ¡we ¡allow ¡UDF ¡approximaKon ¡algorithms ¡

– Which ¡exact ¡operators ¡can ¡they ¡replace ¡ – QuanKfying ¡the ¡tradeoffs ¡ – Placement ¡& ¡Scheduling ¡

slide-30
SLIDE 30

DC3 ¡

¡ ¡ ¡

DC1 ¡ ¡ ¡ ¡

ApproximaKon ¡ComposiKon ¡

Count ¡ ParKal ¡

DC2 ¡ ¡ ¡ ¡

Count ¡ ParKal ¡

If ¡we ¡approximate ¡count, ¡how ¡does ¡that ¡ error ¡affect ¡sort ¡& ¡final ¡answer? ¡

Union ¡ Count ¡ Sort ¡ Limit ¡ Error=e ¡ Error=? ¡

slide-31
SLIDE 31

DC3 ¡

¡ ¡ ¡

DC1 ¡ ¡ ¡ ¡

ApproximaKons ¡in ¡Uneven ¡Networks ¡

Count ¡ ParKal ¡

DC2 ¡ ¡ ¡ ¡

Count ¡ ParKal ¡

Do ¡we ¡need ¡to ¡approximate ¡link ¡DC1-­‑DC3 ¡if ¡ we ¡approximate ¡link ¡DC2-­‑DC3? ¡

Union ¡ Count ¡ Sort ¡ Limit ¡ Low ¡Bandwidth ¡Link; ¡Needs ¡ApproximaKon ¡ ¡ High ¡Bandwidth ¡Link ¡

slide-32
SLIDE 32

Discovering ¡data ¡trends? ¡

  • How ¡has ¡top-­‑k ¡changed ¡over ¡past ¡hour? ¡

¡

  • Current ¡streaming ¡systems ¡don’t ¡answer ¡this ¡

– Except ¡by ¡using ¡centralized ¡DBs. ¡

¡

  • JetStream ¡proposes ¡using ¡storage ¡at ¡the ¡edges ¡
slide-33
SLIDE 33

Hypercube ¡Data ¡Structure ¡

Google ¡ Yahoo ¡ <5Kb ¡ (10, ¡5ms) ¡ (100,20ms) ¡ 50Kb-­‑ 1Mb ¡ (0, ¡0ms) ¡ (1, ¡4ms) ¡ >1Mb ¡ (5,10ms ¡ (5, ¡30ms) ¡ Minute ¡ 1 ¡ … ¡ 60 ¡

slide-34
SLIDE 34

Hypercube ¡Data ¡Structure ¡

Day ¡ Hour ¡ Minute ¡ 1 ¡ … ¡ 31 ¡ 1 ¡ … ¡ 24 ¡ 1 ¡ … ¡ 60 ¡ All ¡ 01 ¡ … ¡ 12 ¡ Month ¡

slide-35
SLIDE 35

Hypercube ¡Data ¡Structure ¡

Day ¡ Hour ¡ Minute ¡ 1 ¡ … ¡ 31 ¡ 1 ¡ … ¡ 24 ¡ 1 ¡ … ¡ 60 ¡ All ¡ 01 ¡ … ¡ 12 ¡ Month ¡ Aggregate ¡ Google ¡ Yahoo ¡ <5Kb ¡ (90, ¡9ms) ¡ (500,20ms) ¡ 50Kb-­‑ 1Mb ¡ (0, ¡0ms) ¡ (5, ¡9ms) ¡ >1Mb ¡ (5,10ms ¡ (10, ¡30ms) ¡

slide-36
SLIDE 36

Query: ¡“Last ¡Hour ¡and ¡a ¡half” ¡

(without ¡materializing ¡intermediate ¡nodes) ¡

Day ¡ Hour ¡ Minute ¡ 1 ¡ … ¡ 31 ¡ 1 ¡ … ¡ 2 ¡ 1 ¡ … ¡ 60 ¡ All ¡ 01 ¡ … ¡ 12 ¡ Month ¡ 1 ¡ … ¡30 ¡ … ¡

slide-37
SLIDE 37

Query: ¡“Last ¡Hour ¡and ¡a ¡half” ¡

by ¡materializing ¡intermediate ¡nodes ¡

Day ¡ Hour ¡ Minute ¡ 1 ¡ … ¡ 31 ¡ 1 ¡ … ¡ 2 ¡ 1 ¡ … ¡ 60 ¡ All ¡ 01 ¡ … ¡ 12 ¡ Month ¡ 1 ¡ … ¡30 ¡ … ¡

slide-38
SLIDE 38

Historical ¡Queries ¡

  • Hypercubes ¡have ¡been ¡used ¡before ¡

– In ¡the ¡database ¡literature ¡

  • What’s ¡Novel ¡

– Storage ¡at ¡the ¡edges ¡(and ¡in ¡the ¡network) ¡ – Time ¡hierarchy ¡

slide-39
SLIDE 39

Challenges ¡we ¡talked ¡about ¡

  • Query ¡placement ¡and ¡scheduling ¡
  • ApproximaKon ¡of ¡answers ¡
  • SupporKng ¡User ¡Defined ¡FuncKons ¡(UDFs) ¡
  • Queries ¡on ¡historical ¡data ¡
  • AdaptaKon ¡to ¡network ¡changes ¡
  • Handling ¡node ¡failures ¡
slide-40
SLIDE 40

Conclusion ¡

JetStream ¡Explores… ¡

+ ¡Stream ¡Processing ¡ + ¡Historical ¡Data ¡/ ¡Trend ¡Analysis ¡ + ¡Wide ¡Area ¡

¡

Thanks! ¡

arye@cs.princeton.edu ¡