SlideShare a Scribd company logo
Minimizing
Coordination in Replicated systems
Cheng Li
Max Planck Institute for Software Systems
Joint work with João Leitão, Allen Clement, Nuno Preguiça, and Rodrigo Rodrigues
MPI-SWS/NOVALINCS
Fast Internet services
Build replicated systems that are fast and correct
4/13/2015 Cheng Li @ PaPoC'15 2
[Making Geo-Replicated Systems Fast as Possible, Consistent when necessary, OSDI’12]
MPI-SWS/NOVALINCS
Fast Internet services
Build replicated systems that are fast and correct
4/13/2015 Cheng Li @ PaPoC'15
Blue ops: no coordination, weak consistency
3
[Making Geo-Replicated Systems Fast as Possible, Consistent when necessary, OSDI’12]
MPI-SWS/NOVALINCS
Fast Internet services
Build replicated systems that are fast and correct
4/13/2015 Cheng Li @ PaPoC'15
State
convergence
Invariant
preservation
Blue ops: no coordination, weak consistency
4
[Making Geo-Replicated Systems Fast as Possible, Consistent when necessary, OSDI’12]
MPI-SWS/NOVALINCS
Fast Internet services
Build replicated systems that are fast and correct
4/13/2015 Cheng Li @ PaPoC'15
Blue ops: no coordination, weak consistency
Red ops: coordination, stronger consistency
5
State
convergence
Invariant
preservation
[Making Geo-Replicated Systems Fast as Possible, Consistent when necessary, OSDI’12]
MPI-SWS/NOVALINCS
How to coordinate red ops?
• Totally order all of them
– simple but sometimes too conservative/costly
• Observation: a red op only needs to be ordered w.r.t
other relevant red ops.
• E.g., auction service
– Bid + close auction operations
– Invariant: highest accepted bid is declared winner
4/13/2015 Cheng Li @ PaPoC'15 6
MPI-SWS/NOVALINCS
bidder price
Replicated auction service
7Cheng Li @ PaPoC'154/13/2015
UKUS
bid($10)
winner bidder price
Bob 10
winner bidder price
MPI-SWS/NOVALINCS
bidder price
Replicated auction service
8Cheng Li @ PaPoC'154/13/2015
UKUS
winner bidder price
Bob 10
winner bidder price
bid($15)
bidder price
Alice 15
MPI-SWS/NOVALINCS
bidder price
Replicated auction service
9Cheng Li @ PaPoC'154/13/2015
UKUS
winner bidder price
Bob 10
winner bidder pricebidder price
Alice 15
close()
winner
Bob
MPI-SWS/NOVALINCS
Replicated auction service
10Cheng Li @ PaPoC'154/13/2015
UKUS
Bob won even with a lower bid than Alice.
bidder price
Bob 10
winner bidder price
Alice 15
winner
Bob
bidder price
Alice 15
Bob 10
bidder price
Alice 15
Bob 10
winner
Bob
MPI-SWS/NOVALINCS
Less coordination is better!
4/13/2015 Cheng Li @ PaPoC'15 11
bid
bid
close
bid
bid
bid
close
bid
bid
MPI-SWS/NOVALINCS
Less coordination is better!
4/13/2015 Cheng Li @ PaPoC'15 12
bid
bid
close
bid
bid
bid
close
bid
bid
Visibility
restriction
A partial order
enforcing visibility
restrictions
Pros: fine-grained tuning in consistency semantics (the
amount of coordination) using restrictions
MPI-SWS/NOVALINCS
Outline
• Background
• Partial order-Restriction (PoR) consistency
– Visibility restrictions
– Consistency model
• Restriction inference
• Conclusion
4/13/2015 Cheng Li @ PaPoC'15 13
MPI-SWS/NOVALINCS
Outline
• Background
• Partial order-Restriction (PoR) consistency
– Visibility restrictions
– Consistency model
• Restriction inference
• Conclusion
4/13/2015 Cheng Li @ PaPoC'15 14
MPI-SWS/NOVALINCS
Visibility restrictions
• A restriction between two operations implies that
one must see effects introduced by the other.
• For operation 𝑎, 𝑏, the restriction 𝑟 𝑎, 𝑏 implies that
𝑎 ≺ 𝑏 𝑏 ≺ 𝑎 w.r.t any partial order ≺.
4/13/2015 Cheng Li @ PaPoC'15 15
a0
b0
a1
a2
b1
b2
If 𝑎 ≺ 𝑏 𝑏 ≺ 𝑎,
then 𝑟 𝑎, 𝑏 is met in ≺.
MPI-SWS/NOVALINCS
Partial order-restrictions (PoR) Consistency
• A replicated system 𝑆 is associated with a set
of restrictions 𝑅𝑠.
– e.g., 𝑅𝑠 = {𝑟(𝑎, 𝑏), 𝑟(𝑐, 𝑑)}
• 𝑆 is PoR Consistent if, for any its executions,
there exists an admissible partial order, where
all restrictions in 𝑅𝑠 are met.
4/13/2015 Cheng Li @ PaPoC'15 16
MPI-SWS/NOVALINCS
Outline
• Background
• Partial order-Restriction (PoR) consistency
– Visibility restrictions
– Consistency model
• Restriction inference
• Conclusion
4/13/2015 Cheng Li @ PaPoC'15 17
MPI-SWS/NOVALINCS
Challenges
• Which restrictions are sufficient?
– They must ensure relevant properties.
• Does the set of restrictions comprise a minimal
coordination plan?
– i.e., we cannot remove any restriction from the set.
4/13/2015 Cheng Li @ PaPoC'15 18
MPI-SWS/NOVALINCS
Outline
• Background
• Partial order-Restriction (PoR) consistency
• Restriction inference
– State convergence
– Invariant preservation
• Conclusion
4/13/2015 Cheng Li @ PaPoC'15 19
MPI-SWS/NOVALINCS
State convergence
• Definition: all replicas reach the same final state
when the system becomes quiescent.
• Insight: any pair of operations must be ordered if
they don’t commute.
4/13/2015 Cheng Li @ PaPoC'15 20
MPI-SWS/NOVALINCS
Invariant preservation
• Insight: for any violation, add restrictions among
concurrent operations
4/13/2015 Cheng Li @ PaPoC'15 21
bid(“Bob”, 10)
bid(“Alice”, 15)
close()
winner bidder price
winner
Bob
bidder price
Alice 15
Bob 10
MPI-SWS/NOVALINCS
Invariant preservation (cont.)
• Insight: for any violation, add restrictions among
concurrent operations
4/13/2015 Cheng Li @ PaPoC'15 22
bid(“Bob”, 10)
bid(“Alice”, 15)
close()
winner bidder price
winner
Bob
bidder price
Alice 15
Bob 10
Q: Can we remove any concurrent
op while maintaining the violation?
MPI-SWS/NOVALINCS
Invariant preservation (cont.)
• Insight: for any violation, add restrictions among
concurrent operations
4/13/2015 Cheng Li @ PaPoC'15 23
bid(“Bob”, 10)
bid(“Alice”, 15)
winner bidder price
winner bidder price
Alice 15
Bob 10
Q: Can we remove any concurrent
op while maintaining the violation?
A: close must be there.
MPI-SWS/NOVALINCS
Invariant preservation (cont.)
• Insight: for any violation, add restrictions among
concurrent operations
4/13/2015 Cheng Li @ PaPoC'15 24
bid(“Bob”, 10)
bid(“Alice”, 15)
close()
winner bidder price
winner
Bob
bidder price
Alice 15
Bob 10
Q: Can we remove any concurrent
op while maintaining the violation?
MPI-SWS/NOVALINCS
Invariant preservation (cont.)
• Insight: for any violation, add restrictions among
concurrent operations
4/13/2015 Cheng Li @ PaPoC'15 25
bid(“Alice”, 15)
close()
winner bidder price
Bob 10
winner
Bob
bidder price
Alice 15
Bob 10
Q: Can we remove any concurrent
op while maintaining the violation?
A: Yes, bid(“Bob”, 10).
MPI-SWS/NOVALINCS
Invariant preservation (cont.)
• Insight: for any violation, add restrictions among
concurrent operations
4/13/2015 Cheng Li @ PaPoC'15 26
bid(“Alice”, 15)
close()
winner bidder price
Bob 10
winner
Bob
bidder price
Alice 15
Bob 10
This is a minimal violating execution.
Solution: 𝑟(𝑏𝑖𝑑, 𝑐𝑙𝑜𝑠𝑒)
Analysis:
Step 1: For any such an execution, we
add a restriction over a pair of its maximal
operations.
Step 2: Iterate all these executions
MPI-SWS/NOVALINCS
Take-home points
• Consistency semantics can be captured by visibility
restrictions over operations.
• Invariant and commutativity analysis finds the
minimal set of restrictions to preserve convergence
and invariants.
• PoR Consistency enforces all restrictions throughout
all executions of a replicated system.
4/13/2015 Cheng Li @ PaPoC'15 27
Minimizing
Coordination in Replicated systems
Thanks for your attention!

More Related Content

PPTX
Webinar: Load Testing for Your Peak Season
PDF
How To Introduce Cloud Based Load Testing to Your Jenkins Continuous Delivery...
PPT
Agile Load Testing In The Real World
PPTX
Testing In Production (TiP) Advances with Big Data & the Cloud
PDF
Come creare un progetto con pipeline CI/CD e con Kubernetes
PDF
Do you know your production?
PDF
DevOps Training - Ho Chi Minh City
PPTX
Evaluation Question 5
Webinar: Load Testing for Your Peak Season
How To Introduce Cloud Based Load Testing to Your Jenkins Continuous Delivery...
Agile Load Testing In The Real World
Testing In Production (TiP) Advances with Big Data & the Cloud
Come creare un progetto con pipeline CI/CD e con Kubernetes
Do you know your production?
DevOps Training - Ho Chi Minh City
Evaluation Question 5

Viewers also liked (18)

PDF
تقرير التعليم المدمج1
PDF
7 clés pour bien choisir un livre
DOCX
Implementaciion de-proyecto
PPT
öRgütsel güven
PPTX
Expo consultoria
PDF
Znr2003Suv_765987ZK
DOCX
Que es la vidda
DOC
Reference letter
PPTX
AMA Career in Focus:
PPTX
الاضافة
PDF
free mHealth Checklist
PDF
ClearRoadmap Features One Pager
PDF
2º basico a 27 de noviembre
PPT
örgütsel güven
PPS
Les plus bellesvagues des marées
DOCX
Dddddddfff
PPTX
Seguridad informática
PPTX
γ2 χάρτεςσημάτων
تقرير التعليم المدمج1
7 clés pour bien choisir un livre
Implementaciion de-proyecto
öRgütsel güven
Expo consultoria
Znr2003Suv_765987ZK
Que es la vidda
Reference letter
AMA Career in Focus:
الاضافة
free mHealth Checklist
ClearRoadmap Features One Pager
2º basico a 27 de noviembre
örgütsel güven
Les plus bellesvagues des marées
Dddddddfff
Seguridad informática
γ2 χάρτεςσημάτων
Ad

Similar to Minimizing Coordination in Replicated Systems (20)

PDF
Functest in Depth
PDF
They don't call it Continuous Integration for nothing!
PPTX
Solid State Deployments: Recommendations for POCs
PPTX
Soasta | CloudBees webinar 11/12/2015
PDF
Bayesian methods in reliability engineering
PDF
Reactive streams
PPTX
Flow Product Development
PDF
Exhaustively Test Any Basic UI or API in 30 Minutes: The Ideal for Any Organi...
PDF
Cwin16 tls-s2-implementing a dev ops pipeline
PPTX
OPNFV: Open Source Carrier Networking Panel
PDF
Shift Remote: DevOps: Gitlab ci hands-on experience - Ivan Rimac (Barrage)
PPTX
Continuous Testing
PDF
Explore the State of Open Source Performance Testing in Continuous Delivery P...
PPTX
Get Ready for Changes To Load Testing
PDF
A True Story of Why QA Loves DevOps
PDF
To Microservices and Beyond
PDF
Tech Talk: The New CA Application Performance Management Team Center—Faster T...
PDF
How to Thrive on REST/WebSocket-Based Microservices
PPT
Continuous Load Testing with CloudTest and Jenkins
PDF
Intro: OPFNV Mini Summit at 2015 NFV World Congress
Functest in Depth
They don't call it Continuous Integration for nothing!
Solid State Deployments: Recommendations for POCs
Soasta | CloudBees webinar 11/12/2015
Bayesian methods in reliability engineering
Reactive streams
Flow Product Development
Exhaustively Test Any Basic UI or API in 30 Minutes: The Ideal for Any Organi...
Cwin16 tls-s2-implementing a dev ops pipeline
OPNFV: Open Source Carrier Networking Panel
Shift Remote: DevOps: Gitlab ci hands-on experience - Ivan Rimac (Barrage)
Continuous Testing
Explore the State of Open Source Performance Testing in Continuous Delivery P...
Get Ready for Changes To Load Testing
A True Story of Why QA Loves DevOps
To Microservices and Beyond
Tech Talk: The New CA Application Performance Management Team Center—Faster T...
How to Thrive on REST/WebSocket-Based Microservices
Continuous Load Testing with CloudTest and Jenkins
Intro: OPFNV Mini Summit at 2015 NFV World Congress
Ad

Recently uploaded (20)

PPTX
Database Infoormation System (DBIS).pptx
PPTX
Business Acumen Training GuidePresentation.pptx
PDF
Recruitment and Placement PPT.pdfbjfibjdfbjfobj
PDF
Fluorescence-microscope_Botany_detailed content
PPTX
CEE 2 REPORT G7.pptxbdbshjdgsgjgsjfiuhsd
PPT
Reliability_Chapter_ presentation 1221.5784
PPTX
Supervised vs unsupervised machine learning algorithms
PPTX
STUDY DESIGN details- Lt Col Maksud (21).pptx
PPTX
Introduction-to-Cloud-ComputingFinal.pptx
PDF
Mega Projects Data Mega Projects Data
PPTX
Computer network topology notes for revision
PPTX
05. PRACTICAL GUIDE TO MICROSOFT EXCEL.pptx
PPTX
iec ppt-1 pptx icmr ppt on rehabilitation.pptx
PPTX
Data_Analytics_and_PowerBI_Presentation.pptx
PPT
Chapter 3 METAL JOINING.pptnnnnnnnnnnnnn
PPT
Quality review (1)_presentation of this 21
PPTX
DISORDERS OF THE LIVER, GALLBLADDER AND PANCREASE (1).pptx
PPTX
IB Computer Science - Internal Assessment.pptx
PPTX
Acceptance and paychological effects of mandatory extra coach I classes.pptx
PDF
“Getting Started with Data Analytics Using R – Concepts, Tools & Case Studies”
Database Infoormation System (DBIS).pptx
Business Acumen Training GuidePresentation.pptx
Recruitment and Placement PPT.pdfbjfibjdfbjfobj
Fluorescence-microscope_Botany_detailed content
CEE 2 REPORT G7.pptxbdbshjdgsgjgsjfiuhsd
Reliability_Chapter_ presentation 1221.5784
Supervised vs unsupervised machine learning algorithms
STUDY DESIGN details- Lt Col Maksud (21).pptx
Introduction-to-Cloud-ComputingFinal.pptx
Mega Projects Data Mega Projects Data
Computer network topology notes for revision
05. PRACTICAL GUIDE TO MICROSOFT EXCEL.pptx
iec ppt-1 pptx icmr ppt on rehabilitation.pptx
Data_Analytics_and_PowerBI_Presentation.pptx
Chapter 3 METAL JOINING.pptnnnnnnnnnnnnn
Quality review (1)_presentation of this 21
DISORDERS OF THE LIVER, GALLBLADDER AND PANCREASE (1).pptx
IB Computer Science - Internal Assessment.pptx
Acceptance and paychological effects of mandatory extra coach I classes.pptx
“Getting Started with Data Analytics Using R – Concepts, Tools & Case Studies”

Minimizing Coordination in Replicated Systems

  • 1. Minimizing Coordination in Replicated systems Cheng Li Max Planck Institute for Software Systems Joint work with João Leitão, Allen Clement, Nuno Preguiça, and Rodrigo Rodrigues
  • 2. MPI-SWS/NOVALINCS Fast Internet services Build replicated systems that are fast and correct 4/13/2015 Cheng Li @ PaPoC'15 2 [Making Geo-Replicated Systems Fast as Possible, Consistent when necessary, OSDI’12]
  • 3. MPI-SWS/NOVALINCS Fast Internet services Build replicated systems that are fast and correct 4/13/2015 Cheng Li @ PaPoC'15 Blue ops: no coordination, weak consistency 3 [Making Geo-Replicated Systems Fast as Possible, Consistent when necessary, OSDI’12]
  • 4. MPI-SWS/NOVALINCS Fast Internet services Build replicated systems that are fast and correct 4/13/2015 Cheng Li @ PaPoC'15 State convergence Invariant preservation Blue ops: no coordination, weak consistency 4 [Making Geo-Replicated Systems Fast as Possible, Consistent when necessary, OSDI’12]
  • 5. MPI-SWS/NOVALINCS Fast Internet services Build replicated systems that are fast and correct 4/13/2015 Cheng Li @ PaPoC'15 Blue ops: no coordination, weak consistency Red ops: coordination, stronger consistency 5 State convergence Invariant preservation [Making Geo-Replicated Systems Fast as Possible, Consistent when necessary, OSDI’12]
  • 6. MPI-SWS/NOVALINCS How to coordinate red ops? • Totally order all of them – simple but sometimes too conservative/costly • Observation: a red op only needs to be ordered w.r.t other relevant red ops. • E.g., auction service – Bid + close auction operations – Invariant: highest accepted bid is declared winner 4/13/2015 Cheng Li @ PaPoC'15 6
  • 7. MPI-SWS/NOVALINCS bidder price Replicated auction service 7Cheng Li @ PaPoC'154/13/2015 UKUS bid($10) winner bidder price Bob 10 winner bidder price
  • 8. MPI-SWS/NOVALINCS bidder price Replicated auction service 8Cheng Li @ PaPoC'154/13/2015 UKUS winner bidder price Bob 10 winner bidder price bid($15) bidder price Alice 15
  • 9. MPI-SWS/NOVALINCS bidder price Replicated auction service 9Cheng Li @ PaPoC'154/13/2015 UKUS winner bidder price Bob 10 winner bidder pricebidder price Alice 15 close() winner Bob
  • 10. MPI-SWS/NOVALINCS Replicated auction service 10Cheng Li @ PaPoC'154/13/2015 UKUS Bob won even with a lower bid than Alice. bidder price Bob 10 winner bidder price Alice 15 winner Bob bidder price Alice 15 Bob 10 bidder price Alice 15 Bob 10 winner Bob
  • 11. MPI-SWS/NOVALINCS Less coordination is better! 4/13/2015 Cheng Li @ PaPoC'15 11 bid bid close bid bid bid close bid bid
  • 12. MPI-SWS/NOVALINCS Less coordination is better! 4/13/2015 Cheng Li @ PaPoC'15 12 bid bid close bid bid bid close bid bid Visibility restriction A partial order enforcing visibility restrictions Pros: fine-grained tuning in consistency semantics (the amount of coordination) using restrictions
  • 13. MPI-SWS/NOVALINCS Outline • Background • Partial order-Restriction (PoR) consistency – Visibility restrictions – Consistency model • Restriction inference • Conclusion 4/13/2015 Cheng Li @ PaPoC'15 13
  • 14. MPI-SWS/NOVALINCS Outline • Background • Partial order-Restriction (PoR) consistency – Visibility restrictions – Consistency model • Restriction inference • Conclusion 4/13/2015 Cheng Li @ PaPoC'15 14
  • 15. MPI-SWS/NOVALINCS Visibility restrictions • A restriction between two operations implies that one must see effects introduced by the other. • For operation 𝑎, 𝑏, the restriction 𝑟 𝑎, 𝑏 implies that 𝑎 ≺ 𝑏 𝑏 ≺ 𝑎 w.r.t any partial order ≺. 4/13/2015 Cheng Li @ PaPoC'15 15 a0 b0 a1 a2 b1 b2 If 𝑎 ≺ 𝑏 𝑏 ≺ 𝑎, then 𝑟 𝑎, 𝑏 is met in ≺.
  • 16. MPI-SWS/NOVALINCS Partial order-restrictions (PoR) Consistency • A replicated system 𝑆 is associated with a set of restrictions 𝑅𝑠. – e.g., 𝑅𝑠 = {𝑟(𝑎, 𝑏), 𝑟(𝑐, 𝑑)} • 𝑆 is PoR Consistent if, for any its executions, there exists an admissible partial order, where all restrictions in 𝑅𝑠 are met. 4/13/2015 Cheng Li @ PaPoC'15 16
  • 17. MPI-SWS/NOVALINCS Outline • Background • Partial order-Restriction (PoR) consistency – Visibility restrictions – Consistency model • Restriction inference • Conclusion 4/13/2015 Cheng Li @ PaPoC'15 17
  • 18. MPI-SWS/NOVALINCS Challenges • Which restrictions are sufficient? – They must ensure relevant properties. • Does the set of restrictions comprise a minimal coordination plan? – i.e., we cannot remove any restriction from the set. 4/13/2015 Cheng Li @ PaPoC'15 18
  • 19. MPI-SWS/NOVALINCS Outline • Background • Partial order-Restriction (PoR) consistency • Restriction inference – State convergence – Invariant preservation • Conclusion 4/13/2015 Cheng Li @ PaPoC'15 19
  • 20. MPI-SWS/NOVALINCS State convergence • Definition: all replicas reach the same final state when the system becomes quiescent. • Insight: any pair of operations must be ordered if they don’t commute. 4/13/2015 Cheng Li @ PaPoC'15 20
  • 21. MPI-SWS/NOVALINCS Invariant preservation • Insight: for any violation, add restrictions among concurrent operations 4/13/2015 Cheng Li @ PaPoC'15 21 bid(“Bob”, 10) bid(“Alice”, 15) close() winner bidder price winner Bob bidder price Alice 15 Bob 10
  • 22. MPI-SWS/NOVALINCS Invariant preservation (cont.) • Insight: for any violation, add restrictions among concurrent operations 4/13/2015 Cheng Li @ PaPoC'15 22 bid(“Bob”, 10) bid(“Alice”, 15) close() winner bidder price winner Bob bidder price Alice 15 Bob 10 Q: Can we remove any concurrent op while maintaining the violation?
  • 23. MPI-SWS/NOVALINCS Invariant preservation (cont.) • Insight: for any violation, add restrictions among concurrent operations 4/13/2015 Cheng Li @ PaPoC'15 23 bid(“Bob”, 10) bid(“Alice”, 15) winner bidder price winner bidder price Alice 15 Bob 10 Q: Can we remove any concurrent op while maintaining the violation? A: close must be there.
  • 24. MPI-SWS/NOVALINCS Invariant preservation (cont.) • Insight: for any violation, add restrictions among concurrent operations 4/13/2015 Cheng Li @ PaPoC'15 24 bid(“Bob”, 10) bid(“Alice”, 15) close() winner bidder price winner Bob bidder price Alice 15 Bob 10 Q: Can we remove any concurrent op while maintaining the violation?
  • 25. MPI-SWS/NOVALINCS Invariant preservation (cont.) • Insight: for any violation, add restrictions among concurrent operations 4/13/2015 Cheng Li @ PaPoC'15 25 bid(“Alice”, 15) close() winner bidder price Bob 10 winner Bob bidder price Alice 15 Bob 10 Q: Can we remove any concurrent op while maintaining the violation? A: Yes, bid(“Bob”, 10).
  • 26. MPI-SWS/NOVALINCS Invariant preservation (cont.) • Insight: for any violation, add restrictions among concurrent operations 4/13/2015 Cheng Li @ PaPoC'15 26 bid(“Alice”, 15) close() winner bidder price Bob 10 winner Bob bidder price Alice 15 Bob 10 This is a minimal violating execution. Solution: 𝑟(𝑏𝑖𝑑, 𝑐𝑙𝑜𝑠𝑒) Analysis: Step 1: For any such an execution, we add a restriction over a pair of its maximal operations. Step 2: Iterate all these executions
  • 27. MPI-SWS/NOVALINCS Take-home points • Consistency semantics can be captured by visibility restrictions over operations. • Invariant and commutativity analysis finds the minimal set of restrictions to preserve convergence and invariants. • PoR Consistency enforces all restrictions throughout all executions of a replicated system. 4/13/2015 Cheng Li @ PaPoC'15 27
  • 28. Minimizing Coordination in Replicated systems Thanks for your attention!