SlideShare a Scribd company logo
1 of 55
Download to read offline
Dennis van der Stelt
of distributed systems
Dennis van der Stelt
Software Architect
http://dennis.bloggingabout.net/
dennis@bloggingabout.net
NServiceBus Community Champ
PRINCIPLES
@dvdstelt
#sdnevent
Dennis van der Stelt
YOUR PRESENTER
Dennis van der Stelt
http://dennis.bloggingabout.net/
Software Architect
Professional Services
Provides coaching & training
About Dennis
Innovative software architect
Almost 20 years of experience in development of
distributed systems. Has a continuous drive to
learn and improve knowledge in different
architectural styles, including quality in software
development. Highly motivated to share his
knowledge via articles, presentations and his
blog.
Awards
NServiceBus Champ
Typemock MVP
Certified Trainer
• Presentations
• Software & Architecture audits
• SOA & Microservices advice
• Unit Testing training
• NServiceBus training
Presentations
October 15th at Blaak Selectie / Betabit
Reliable systems using messaging
Dennis van der Stelt
AGENDA
Dennis van der Stelt
A monolithic design is characterized by such tight coupling
among modules that they really have no independent existence.
monolithic
Dennis van der Stelt
MONOLITHIC DESIGN
How does my clean code become a big ball of mud?
Database
Dennis van der Stelt
MONOLITHIC DESIGN
How does my clean code become a big ball of mud?
Database
Dennis van der Stelt
Dennis van der Stelt
What’s your problem, dude?
Dennis van der Stelt
PROBLEM STATEMENT
Layering
Problem #1
Dennis van der Stelt
Dennis van der Stelt
lightweight servicebus
Dennis van der Stelt
PROBLEM STATEMENT
“little computers
passing messages”
Problem #2
alan kay http://bit.ly/alankay-oo
reduce
coupling
Dennis van der Stelt
SpatialTemporalPlatform
coupling aspects
Dennis van der Stelt
TEMPORAL
Store Front End Shipping Service
Dennis van der Stelt
TEMPORAL
Store Front End Shipping ServiceShipping Service
Dennis van der Stelt
TEMPORAL
Store Front End Shipping ServiceOrder Queue
Dennis van der Stelt
TEMPORAL
Store Front End Shipping ServiceOrder Queue
Dennis van der Stelt
TEMPORAL
Store Front End Shipping ServiceOrder Queue
Dennis van der Stelt
Messaging
 Reduces spatial coupling
 Solves platform coupling
 Asynchronous for temporal coupling
Dennis van der Stelt
CAP Theorem
Eric Brewer, PODC Conference 2000
Dennis van der Stelt
CAP THEOREM
You can only pick 2
Dennis van der Stelt
CAP THEOREM
You can only pick 2
centralized
system
partition tolerantconsistencyavailability
Dennis van der Stelt
CAP THEOREM
You can only pick 2
centralized
system
partition tolerantconsistencyavailability
Dennis van der Stelt
CAP THEOREM
You can only pick 2
centralized
system
partition tolerantconsistencyavailability
distributed
system
partition tolerantconsistencyavailability
Dennis van der Stelt
CAP THEOREM
You can only pick 2
centralized
system
partition tolerantconsistencyavailability
distributed
system
partition tolerantconsistencyavailability
when there’s network partition,
which do you sacrifice?
Dennis van der Stelt
Match the business perspective
Dennis van der Stelt
Dennis van der Stelt
Dennis van der Stelt
Dennis van der Stelt
But I can’t drop consistency!
Dennis van der Stelt
Basically Available
BASE
What is BASE?
Soft state
Eventually consistent
Dennis van der Stelt
Eventual Consistency
Because 100% consistency isn’t the only option
Dennis van der Stelt
Dennis van der Stelt
Eventual Consistency
Dennis van der Stelt
Eventual Consistency
Dennis van der Stelt
Eventual Consistency
your “enterprise” is already eventual consistent with reality
Dennis van der Stelt
Eventual Consistency
your “enterprise” is already eventual consistent with reality
Dennis van der Stelt
“Allow things to be inconsistent and find ways to
compensate for mistakes, versus trying to prevent
mistakes altogether.”
EVENTUAL CONSISTENCY
Eric Brewer
VP of Infrastructure at Google, Professor at UC Berkeley
Dennis van der Stelt
Some ideas on messaging
Dennis van der Stelt
100% synchronized
that‘s eventual consistency.
Udi Dahanin 2010
Dennis van der Stelt
Distributed Transactions
Are they as evil as you think? Perhaps even more?
Dennis van der Stelt
Who uses distributed transactions?
Dennis van der Stelt
using (var scope = new TransactionScope()))
{
var queue = new
MessageQueue(@".Private$Customers");
var message = queue.Receive();
var con = new SqlConnection();
var cmd = new SqlCommand("update customers ...");
cmd.ExecuteNonQuery();
}
DISTRIBUTED TRANSACTIONS
Microsoft Distributed Transaction Coordinator (MSDTC)
Code
Dennis van der Stelt
using (var scope = new TransactionScope()))
{
var queue = new
MessageQueue(@".Private$Customers");
var message = queue.Receive();
var con = new SqlConnection();
var cmd = new SqlCommand("update customers ...");
cmd.ExecuteNonQuery();
}
DISTRIBUTED TRANSACTIONS
Microsoft Distributed Transaction Coordinator (MSDTC)
Code
MSDTC
Dennis van der Stelt
Dennis van der Stelt
Distributed Transactions
Dennis van der Stelt49
Idempotency
Once and only once delivery is hard!
Dennis van der Stelt
Dennis van der Stelt
IDEM POTENCY
Solving the distributed transactionissues
Sender
{0C836F44-6587-416E-B97A-5615615600D5}
Dennis van der Stelt
IDEM POTENCY
Solving the distributed transactionissues
Sender
{0C836F44-6587-416E-B97A-5615615600D5}
Dennis van der Stelt
IDEM POTENCY
Solving the distributed transactionissues
Sender
Event
Subscriber
{5EDC4993-AB01-4F17-A238-71C4521F750F}
{0C836F44-6587-416E-B97A-5615615600D5}
Dennis van der Stelt
IDEM POTENCY
Solving the distributed transactionissues
Sender
Event
Subscriber
{5EDC4993-AB01-4F17-A238-71C4521F750F}
{0C836F44-6587-416E-B97A-5615615600D5}
Dennis van der Stelt
Dennis van der Stelt
find me.
http://dennis.bloggingabout.net
dvdstelt@outlook.com

More Related Content

Similar to Distributed Systems principles

How to fail or succeed with desktop virtualization and workspace mobility
How to fail or succeed with desktop virtualization and workspace mobilityHow to fail or succeed with desktop virtualization and workspace mobility
How to fail or succeed with desktop virtualization and workspace mobilityDenis Gundarev
 
Phreebird Suite 1.0: Introducing the Domain Key Infrastructure
Phreebird Suite 1.0:  Introducing the Domain Key InfrastructurePhreebird Suite 1.0:  Introducing the Domain Key Infrastructure
Phreebird Suite 1.0: Introducing the Domain Key InfrastructureDan Kaminsky
 
Change your architecture during deployment
Change your architecture during deploymentChange your architecture during deployment
Change your architecture during deploymentDennis van der Stelt
 
Voyss Cloud
Voyss CloudVoyss Cloud
Voyss Cloudpswaim
 
Deploying Unified Communications with Lync on the easiest, most secure platform
Deploying Unified Communications with Lync on the easiest, most secure platformDeploying Unified Communications with Lync on the easiest, most secure platform
Deploying Unified Communications with Lync on the easiest, most secure platformDell World
 
Presentation citrix desktop virtualization
Presentation   citrix desktop virtualizationPresentation   citrix desktop virtualization
Presentation citrix desktop virtualizationxKinAnx
 
Trade Show Disc Work
Trade Show Disc WorkTrade Show Disc Work
Trade Show Disc WorkBrian Tort
 
ESET: Delivering Benefits to Enterprises
ESET: Delivering Benefits to EnterprisesESET: Delivering Benefits to Enterprises
ESET: Delivering Benefits to EnterprisesESET
 
Innovations that simplify desktop virtualization
Innovations that simplify desktop virtualization Innovations that simplify desktop virtualization
Innovations that simplify desktop virtualization Dell World
 
NextStep Boston 2018 - Monoliths or Microservices, Francisco Menezes
NextStep Boston 2018 - Monoliths or Microservices, Francisco MenezesNextStep Boston 2018 - Monoliths or Microservices, Francisco Menezes
NextStep Boston 2018 - Monoliths or Microservices, Francisco MenezesOutSystems
 
Vdi, rds, med v, app-v - right decisions
Vdi, rds, med v, app-v - right decisionsVdi, rds, med v, app-v - right decisions
Vdi, rds, med v, app-v - right decisionsConcentrated Technology
 
Citrix en Nutanix: de kracht van de combinatie
Citrix en Nutanix: de kracht van de combinatieCitrix en Nutanix: de kracht van de combinatie
Citrix en Nutanix: de kracht van de combinatieICT-Partners
 
IT Pros and The Cloud
IT Pros and The CloudIT Pros and The Cloud
IT Pros and The CloudStephen Rose
 
How to Extend the App Model to Support Your User-Centric XenDesktop in the Da...
How to Extend the App Model to Support Your User-Centric XenDesktop in the Da...How to Extend the App Model to Support Your User-Centric XenDesktop in the Da...
How to Extend the App Model to Support Your User-Centric XenDesktop in the Da...Peter Daalmans
 
101 Presentation Sample
101 Presentation Sample101 Presentation Sample
101 Presentation SampleDataVault
 

Similar to Distributed Systems principles (20)

DNA Cloud Backup
DNA Cloud BackupDNA Cloud Backup
DNA Cloud Backup
 
How to fail or succeed with desktop virtualization and workspace mobility
How to fail or succeed with desktop virtualization and workspace mobilityHow to fail or succeed with desktop virtualization and workspace mobility
How to fail or succeed with desktop virtualization and workspace mobility
 
Phreebird Suite 1.0: Introducing the Domain Key Infrastructure
Phreebird Suite 1.0:  Introducing the Domain Key InfrastructurePhreebird Suite 1.0:  Introducing the Domain Key Infrastructure
Phreebird Suite 1.0: Introducing the Domain Key Infrastructure
 
Change your architecture during deployment
Change your architecture during deploymentChange your architecture during deployment
Change your architecture during deployment
 
Voyss Cloud
Voyss CloudVoyss Cloud
Voyss Cloud
 
Porta ovunque il tuo desktop
Porta ovunque il tuo desktopPorta ovunque il tuo desktop
Porta ovunque il tuo desktop
 
Deploying Unified Communications with Lync on the easiest, most secure platform
Deploying Unified Communications with Lync on the easiest, most secure platformDeploying Unified Communications with Lync on the easiest, most secure platform
Deploying Unified Communications with Lync on the easiest, most secure platform
 
Death of the batch job
Death of the batch jobDeath of the batch job
Death of the batch job
 
Presentation citrix desktop virtualization
Presentation   citrix desktop virtualizationPresentation   citrix desktop virtualization
Presentation citrix desktop virtualization
 
A Xen Case Study
A Xen Case StudyA Xen Case Study
A Xen Case Study
 
Trade Show Disc Work
Trade Show Disc WorkTrade Show Disc Work
Trade Show Disc Work
 
ESET: Delivering Benefits to Enterprises
ESET: Delivering Benefits to EnterprisesESET: Delivering Benefits to Enterprises
ESET: Delivering Benefits to Enterprises
 
Innovations that simplify desktop virtualization
Innovations that simplify desktop virtualization Innovations that simplify desktop virtualization
Innovations that simplify desktop virtualization
 
NextStep Boston 2018 - Monoliths or Microservices, Francisco Menezes
NextStep Boston 2018 - Monoliths or Microservices, Francisco MenezesNextStep Boston 2018 - Monoliths or Microservices, Francisco Menezes
NextStep Boston 2018 - Monoliths or Microservices, Francisco Menezes
 
Vdi, rds, med v, app-v - right decisions
Vdi, rds, med v, app-v - right decisionsVdi, rds, med v, app-v - right decisions
Vdi, rds, med v, app-v - right decisions
 
Citrix en Nutanix: de kracht van de combinatie
Citrix en Nutanix: de kracht van de combinatieCitrix en Nutanix: de kracht van de combinatie
Citrix en Nutanix: de kracht van de combinatie
 
IT Pros and The Cloud
IT Pros and The CloudIT Pros and The Cloud
IT Pros and The Cloud
 
How to Extend the App Model to Support Your User-Centric XenDesktop in the Da...
How to Extend the App Model to Support Your User-Centric XenDesktop in the Da...How to Extend the App Model to Support Your User-Centric XenDesktop in the Da...
How to Extend the App Model to Support Your User-Centric XenDesktop in the Da...
 
Why is Core DX the Best DDS?
Why is Core DX the Best DDS?Why is Core DX the Best DDS?
Why is Core DX the Best DDS?
 
101 Presentation Sample
101 Presentation Sample101 Presentation Sample
101 Presentation Sample
 

More from Dennis van der Stelt

More from Dennis van der Stelt (10)

Dealing with eventual consistency
Dealing with eventual consistencyDealing with eventual consistency
Dealing with eventual consistency
 
Dealing with eventual consistency
Dealing with eventual consistencyDealing with eventual consistency
Dealing with eventual consistency
 
Duplicating data or replicating data in Micro Services
Duplicating data or replicating data in Micro ServicesDuplicating data or replicating data in Micro Services
Duplicating data or replicating data in Micro Services
 
Silverlight & WCF RIA
Silverlight & WCF RIASilverlight & WCF RIA
Silverlight & WCF RIA
 
Test Driven Development
Test Driven DevelopmentTest Driven Development
Test Driven Development
 
AppFabric Velocity
AppFabric VelocityAppFabric Velocity
AppFabric Velocity
 
Continuous integration
Continuous integrationContinuous integration
Continuous integration
 
App fabric introduction
App fabric introductionApp fabric introduction
App fabric introduction
 
SOLID Principles part 2
SOLID Principles part 2SOLID Principles part 2
SOLID Principles part 2
 
SOLID Principles part 1
SOLID Principles part 1SOLID Principles part 1
SOLID Principles part 1
 

Recently uploaded

04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGSujit Pal
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 

Recently uploaded (20)

04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAG
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 

Distributed Systems principles

  • 1. Dennis van der Stelt of distributed systems Dennis van der Stelt Software Architect http://dennis.bloggingabout.net/ dennis@bloggingabout.net NServiceBus Community Champ PRINCIPLES @dvdstelt #sdnevent
  • 2. Dennis van der Stelt YOUR PRESENTER Dennis van der Stelt http://dennis.bloggingabout.net/ Software Architect Professional Services Provides coaching & training About Dennis Innovative software architect Almost 20 years of experience in development of distributed systems. Has a continuous drive to learn and improve knowledge in different architectural styles, including quality in software development. Highly motivated to share his knowledge via articles, presentations and his blog. Awards NServiceBus Champ Typemock MVP Certified Trainer • Presentations • Software & Architecture audits • SOA & Microservices advice • Unit Testing training • NServiceBus training Presentations October 15th at Blaak Selectie / Betabit Reliable systems using messaging
  • 3. Dennis van der Stelt AGENDA
  • 4. Dennis van der Stelt A monolithic design is characterized by such tight coupling among modules that they really have no independent existence. monolithic
  • 5. Dennis van der Stelt MONOLITHIC DESIGN How does my clean code become a big ball of mud? Database
  • 6. Dennis van der Stelt MONOLITHIC DESIGN How does my clean code become a big ball of mud? Database
  • 8. Dennis van der Stelt What’s your problem, dude?
  • 9. Dennis van der Stelt PROBLEM STATEMENT Layering Problem #1
  • 10. Dennis van der Stelt
  • 11. Dennis van der Stelt lightweight servicebus
  • 12. Dennis van der Stelt PROBLEM STATEMENT “little computers passing messages” Problem #2 alan kay http://bit.ly/alankay-oo
  • 14. Dennis van der Stelt SpatialTemporalPlatform coupling aspects
  • 15. Dennis van der Stelt TEMPORAL Store Front End Shipping Service
  • 16. Dennis van der Stelt TEMPORAL Store Front End Shipping ServiceShipping Service
  • 17. Dennis van der Stelt TEMPORAL Store Front End Shipping ServiceOrder Queue
  • 18. Dennis van der Stelt TEMPORAL Store Front End Shipping ServiceOrder Queue
  • 19. Dennis van der Stelt TEMPORAL Store Front End Shipping ServiceOrder Queue
  • 20. Dennis van der Stelt Messaging  Reduces spatial coupling  Solves platform coupling  Asynchronous for temporal coupling
  • 21. Dennis van der Stelt CAP Theorem Eric Brewer, PODC Conference 2000
  • 22. Dennis van der Stelt CAP THEOREM You can only pick 2
  • 23. Dennis van der Stelt CAP THEOREM You can only pick 2 centralized system partition tolerantconsistencyavailability
  • 24. Dennis van der Stelt CAP THEOREM You can only pick 2 centralized system partition tolerantconsistencyavailability
  • 25. Dennis van der Stelt CAP THEOREM You can only pick 2 centralized system partition tolerantconsistencyavailability distributed system partition tolerantconsistencyavailability
  • 26. Dennis van der Stelt CAP THEOREM You can only pick 2 centralized system partition tolerantconsistencyavailability distributed system partition tolerantconsistencyavailability when there’s network partition, which do you sacrifice?
  • 27. Dennis van der Stelt Match the business perspective
  • 28. Dennis van der Stelt
  • 29. Dennis van der Stelt
  • 30. Dennis van der Stelt
  • 31. Dennis van der Stelt But I can’t drop consistency!
  • 32. Dennis van der Stelt Basically Available BASE What is BASE? Soft state Eventually consistent
  • 33. Dennis van der Stelt Eventual Consistency Because 100% consistency isn’t the only option
  • 34. Dennis van der Stelt
  • 35. Dennis van der Stelt Eventual Consistency
  • 36. Dennis van der Stelt Eventual Consistency
  • 37. Dennis van der Stelt Eventual Consistency your “enterprise” is already eventual consistent with reality
  • 38. Dennis van der Stelt Eventual Consistency your “enterprise” is already eventual consistent with reality
  • 39. Dennis van der Stelt “Allow things to be inconsistent and find ways to compensate for mistakes, versus trying to prevent mistakes altogether.” EVENTUAL CONSISTENCY Eric Brewer VP of Infrastructure at Google, Professor at UC Berkeley
  • 40. Dennis van der Stelt Some ideas on messaging
  • 41. Dennis van der Stelt 100% synchronized that‘s eventual consistency. Udi Dahanin 2010
  • 42. Dennis van der Stelt Distributed Transactions Are they as evil as you think? Perhaps even more?
  • 43. Dennis van der Stelt Who uses distributed transactions?
  • 44. Dennis van der Stelt using (var scope = new TransactionScope())) { var queue = new MessageQueue(@".Private$Customers"); var message = queue.Receive(); var con = new SqlConnection(); var cmd = new SqlCommand("update customers ..."); cmd.ExecuteNonQuery(); } DISTRIBUTED TRANSACTIONS Microsoft Distributed Transaction Coordinator (MSDTC) Code
  • 45. Dennis van der Stelt using (var scope = new TransactionScope())) { var queue = new MessageQueue(@".Private$Customers"); var message = queue.Receive(); var con = new SqlConnection(); var cmd = new SqlCommand("update customers ..."); cmd.ExecuteNonQuery(); } DISTRIBUTED TRANSACTIONS Microsoft Distributed Transaction Coordinator (MSDTC) Code MSDTC
  • 46. Dennis van der Stelt
  • 47. Dennis van der Stelt Distributed Transactions
  • 48. Dennis van der Stelt49 Idempotency Once and only once delivery is hard!
  • 49. Dennis van der Stelt
  • 50. Dennis van der Stelt IDEM POTENCY Solving the distributed transactionissues Sender {0C836F44-6587-416E-B97A-5615615600D5}
  • 51. Dennis van der Stelt IDEM POTENCY Solving the distributed transactionissues Sender {0C836F44-6587-416E-B97A-5615615600D5}
  • 52. Dennis van der Stelt IDEM POTENCY Solving the distributed transactionissues Sender Event Subscriber {5EDC4993-AB01-4F17-A238-71C4521F750F} {0C836F44-6587-416E-B97A-5615615600D5}
  • 53. Dennis van der Stelt IDEM POTENCY Solving the distributed transactionissues Sender Event Subscriber {5EDC4993-AB01-4F17-A238-71C4521F750F} {0C836F44-6587-416E-B97A-5615615600D5}
  • 54. Dennis van der Stelt
  • 55. Dennis van der Stelt find me. http://dennis.bloggingabout.net dvdstelt@outlook.com