Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 EventWave: Programming Model and Runtime Support for Tightly-Coupled Elastic Cloud Applications.

Similar presentations


Presentation on theme: "Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 EventWave: Programming Model and Runtime Support for Tightly-Coupled Elastic Cloud Applications."— Presentation transcript:

1 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 EventWave: Programming Model and Runtime Support for Tightly-Coupled Elastic Cloud Applications Wei-Chiu Chuang, Bo Sang, Sunghwan Yoo, Rui Gu, Charles Killian, Milind Kulkarni 1

2 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Motivation 2 clients server world building room Time Response time # clients

3 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Motivation 3 Scale up Time Response time clients server # clients Elasticity is hard

4 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Objectives 4 A programming model which supports: Stateful computation Simple sequential semantics Transparent elasticity

5 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Related Work 5 Data Flow stateless Live Migration Live Migration of Virtual Machines [Clark et. al. NSDI ‘05] Live Migration of Virtual Machines [Clark et. al. NSDI ‘05] Zephyr [Elmore et. al. SIGMOD ‘11] Does not change scale: “split”/”merge” state Scalable programming model Orleans [Bykov et. al. SoCC ‘11] Transactional, reconcile conflicts MapReduce [Dean et. al. OSDI ‘04] Dryad [Isard et. al. EuroSys ‘07] CIEL [Murray et. al. NSDI ‘11] No Stateful Computation No transparent elasticity No simple sequential semantics

6 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 EventWave 6 Stateful computation Simple semantics Transparent elasticity

7 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Event Driven Systems 7 1 2 3 Event 1 commits Event 2 commits Event 3 commits Typical event driven systems are not scalable. Event queue client server

8 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Context 8 world building room  Scalability comes from parallelism  Partition program state into `contexts`  An event accesses one or more contexts  Events accessing disjoint contexts can run in parallel world building room hallway Contexts enable implicit parallelism

9 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 EventWave 9 Event 1 commits Event 2 commits Event 3 commits Event 2 finishes Event 1 finishes Event 3 finishes Context 1 Context 2 Context 3 1 2 3 Enforce sequential ordering Event 2 can not commit until Event 1 commits Enforce sequential ordering Event 2 can not commit until Event 1 commits Stateful Sequential semantics Parallelism Stateful Sequential semantics Parallelism

10 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Access Multiple Contexts  A player can move from one room to another  Remove it from source room  Insert it into destination room 10 world building room Room 1 Room 2 Alice Bob Player list An event may access multiple contexts Bob

11 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Access Multiple Contexts  Must ensure  Sequential semantics  parallelism Event 1 finishes Event 2 commits 1 2 10 To be scalable, events can not access contexts arbitrarily Event 2 can’t start before event 1 finishes Context 1 Context 2 Context 3

12 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Hierarchical Contexts 12 world Building Room  Contexts are not completely independent  The world has many buildings  A building has many rooms

13 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 13 world Building Room  Must access contexts from top to bottom The hierarchical access enables parallelism

14 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 14 world Building Room  Move a player from room 1 to room 2

15 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 15 world Building Room Allow the next event to access Building

16 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 16 world Building Room Enter Room

17 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 17 world Building Room Remove player Release exclusive access

18 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 18 world Building Room Enter Room

19 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 19 world Building Room Insert player Event finishes, releasing all contexts

20 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 20 world Building Room

21 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Wave of Events 21 world Building Room Event commits, releasing snapshot

22 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13  Scale more by executing events across multiple nodes  Map contexts  Head node 22 Distributed Execution Head node world Building Room

23 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 23 Distributed Execution Client Logical Node #1 Client Logical Node #2  Logical Node: a set of physical nodes Server Logical Node

24 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 24 Distributed Execution

25 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 25 Elasticity world Building Room Request nodes from cloud scheduler Update context mapping

26 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 26 Elasticity world Building Room Transfer contexts to the new node

27 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 27 Elasticity world Building Room More Room contexts

28 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Evaluation Does it scale?  Microbechmarks  Scalability What is the cost of migration?  Microbechmarks  Migration latency Case study  Multi-player game server 28 In the paper Key-value store

29 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Microbenchmark-Scalability Setup  One logical node, fixed context mapping  EC2 Small Instances  1 vCPU, 1.7GB RAM, 160 GB local disk  Distribute 160 contexts to physical nodes Measures  Throughput 29

30 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Microbenchmark-Scalability 30 Takeaway: Throughput grows w.r.t. # of nodes Takeaway: Throughput grows w.r.t. # of nodes P: workload

31 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Microbenchmark-Migration Latency 31 Setup  2 x 8-core 2.0 GHz Xeon, 8GB RAM  1Gb Ethernet connection Scale does not change

32 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Microbenchmark-Migration Latency Measure  Throughput of events 32 The migration event commits Finished events must wait for migration event Migrate a 100MB context

33 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Multi-player Game Server 33 Setup  Server logical node  1 x Extra Large Instance (head)  64 x Small Instances  Client logical nodes  128 clients on 16 EC2 Small Instances Measure  Latency

34 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Multi-player Game Server 34 Server contexts spread to 64 physical nodes Synthetic workload Server contexts merge to 1 physical nodes

35 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Conclusion  Elasticity is crucial for cloud applications.  Our programming model enables transparent elasticity for tightly-coupled applications  Case studies show EventWave is efficient 35 http://www.macesystems.org

36 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Backups 36

37 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Language Construct 37 state_variables{ Hallway hw; vector rooms; } state_variables{ Hallway hw; vector rooms; } context Hallway{ int x; } context Room { int y; } context Hallway{ int x; } context Room { int y; } Declare implicit parallelism Mace [Killian et. al. PLDI ‘07] Mace [Killian et. al. PLDI ‘07] Hallway Room[0] Room[1] … Hallway Room

38 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Event Handler 38 upcall deliver(Message m){ } upcall deliver(Message m){ } upcall [Room ] deliver(Message m){ } upcall [Room ] deliver(Message m){ } Annotation Specify what context to access Annotation Specify what context to access Message(roomID = 2) Context Room

39 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Key-value store 39 Setup  2 x 8-core 2.0 GHz Xeon, 8GB RAM  1Gb Ethernet connection Measure  Latency

40 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Key-value store 40

41 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Microbenchmark-Migration Latency 41 Setup  2 x 8-core 2.0 GHz Xeon, 8GB RAM  1Gb Ethernet connection Scale does not change Context

42 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 42 Context Migration Head Old node New node Copy context state Replicate context state Event 1 goes to the old node Event 3 goes to the new node 1 1 M M 3 3 Update context-node mapping

43 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Microbenchmark-Migration Latency  Latency = serialization + deserialization + network transmission 43

44 Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 Multi-player Game Server 44


Download ppt "Chuang, Sang, Yoo, Gu, Killian and Kulkarni, “EventWave” SoCC ‘13 EventWave: Programming Model and Runtime Support for Tightly-Coupled Elastic Cloud Applications."

Similar presentations


Ads by Google