SlideShare a Scribd company logo
1 of 34
Powerful, Distributed, API Communications
Call-in Number: 513.386.0101Pin 705-705-
141
Expert Q&A: Database Edition
May 31st
, 2013
Welcome
Our Panelists
Joshua Goldbard
Marketing Ninja, 2600hz,
Moderator
Darren Schreiber
Founder, 2600hz
Sam Bisbee
Cloudant
Database:
It’s all good until it isn’t
Some background…
What is Database?
• A Record of things Remembered or Forgotten
• Used to be Unbelievably hard, now it’s just hard
sometimes
• Modern Databases are amazingly resilient
• Failure Mode still requires lots of attention
• In Distributed Environments…
• Database is inexorably linked to the network
• The network is always unreliable if public
Masters and Slaves
• Databases have to Replicate
• Most Databases use a form of Master-Slave
Relationship to manage replication and dedupe
• Masters are where new data is entered
• Then it’s mirrored out to the Slaves for storage
• If you lose access to the original Master, you can
convert a Slave into a Master and restore
operation
Durability
Other Replication Strategies
• Other strategies exist, such as…
• Master-Master (What 2600hz Uses)
• Tokenized Exchange
• Time-delimited
• The most popular methods tend to be Master-
Slave or Master-Master
Each Database has its advantages and tradeoffs. Once
again, there is no Magic Bullet.
Failure and Quorum
• When A Database needs to elect a new master…
• There are many different strategies
• Most involve the concept of quorum (figuring
out where the greatest number of copies
reside)
• Once Quorum is established, a new master is
elected and (hopefully) operation can resume
• Quorum is different in Master-Master (Explain)
Cap Theorem
Databases can have (at most) 2 out of 3 of the following:
•Consistency
•Availability
•Partition Tolerance
Modern Database Management is balancing between
Consistency and Availability because all modern
networks are unreliable
Examples of Databases
What is Important in a Database?
• Reliable Storage of Data?
• Fast Retrieval of Data?
• Fast Saving of Data?
• Resilience during failures?
• <other>
Examples
• Buying tickets from ticketmaster
• What’s important and why?
• Withdrawing money from a bank?
• Storing Call Forwarding Settings?
• Storing a List of Favorite Stocks?
Each Scenario has a different set of requirements and
constraints. There is no silver bullet; if you could
write one database for all these scenarios, you’d
be rich.
Which Database is Better?
• STUPID QUESTION
• But I thought there were no stupid questions?
• This is the only stupid question.
• The fight of which database is better is almost
always silly
• Databases are a tool, to get a job done
• Like the previous examples, each job is different
• Each database stresses different pros/cons
Let’s Get Technical!
Trouble With Databases
• HUGE TOPIC (We’re only going to cover a little)
• Network Partitions
• Layer 1 disasters
• Flapping Internet (Special Class of Network
Partitions)
Network Partitions
• Common in Distributed Databases
• When Databases lose contact with each other they can
partition
• Caused by unreliable or faulty network connections
• Databases can behave very weirdly when in partitions
Arguably, most of what a database admin does is prepare for
network partitions and how to resolve them.
Network without Partitions
Network with Partitions
Split-Brain
• During a partition, some databases will elect N masters, one
for each partition in the network.
• When the partition is fixed, unless there is a pre-defined
restoral procedure, there will be conflicts
• Databases have all kinds of strategies for handling WAN Split-
brain failure, but you should understand them
Key Takeaway: No Database is perfect. Understand the
automation but also understand the manual intervention
procedure.
Layer 1 Failures
Layer 1 Failures
• Rut Roh
• Actual Physical Disaster
• No easy way out except…
• Don’t be in a Datacenter that’s hit by a disaster
OR
• Be Nimble enough to Evade Disaster
Evading Disaster
• We’re not Magicians, we can’t simply predict disasters
• The next best thing is being able to move and move fast
• Kazoo requires one line of code to move
• Kazoo moves fast
• Moving the Database fast is awesome (Thanks BigCouch!)
During Hurricane Sandy, we cut our Datacenters away from
Downtown New York to a Datacenter above the 100 year
flood plain on the East Coast. Result: No Downtime.
No Silver Bullets
• Layer 1 disasters are a humbling experience
• Don’t rely on DataCenters in the Path of a Storm
• Flooding will brick datacenters that have generators below
ground
• To avoid being powerless in a disaster…
• Plan, Test, Analyze, Repeat
• Check out Netflix Simian Army for examples of tests
Flapping
• Is it up? Is it Down? Around and Around it Goes, where it
stops nobody knows…
• Flapping Internet is a special case of network partition or lose
connectivity
• Flapping connections lose contact with other servers and then
appear to come back online before going off
Why is this bad?
Fixing Flapping
• I’m trying to fix a partition
• The Network keeps going up and down
• As I repair my cluster, it keeps starting to repair and failing (by
attempting to reintegrate the unreliable nodes)
Flapping nodes make everything awful
Why is the Network Difficult?
“Detecting network failures is hard. Since our only knowledge of
the other nodes passes through the network, delays are
indistinguishable from failure. This is the fundamental problem of
the network partition: latency high enough to be considered a
failure. When partitions arise, we have no way to
determine what happened on the other nodes: are they alive?
Dead? Did they receive our message? Did they try to respond?
Literally no one knows. When the network finally heals, we'll
have to re-establish the connection and try to work out what
happened–perhaps recovering from an inconsistent state.”
-Kyle Kingsbury, Aphyr.com
Why is the Network Difficult?
“Detecting network failures is hard. Since our only knowledge of
the other nodes passes through the network, delays are
indistinguishable from failure. This is the fundamental problem of
the network partition: latency high enough to be considered a
failure. When partitions arise, we have no way to
determine what happened on the other nodes: are they alive?
Dead? Did they receive our message? Did they try to respond?
Literally no one knows. When the network finally heals, we'll
have to re-establish the connection and try to work out what
happened–perhaps recovering from an inconsistent state.”
-Kyle Kingsbury, Aphyr.com
Why is the Network Difficult?
“Detecting network failures is hard. Since our only knowledge of
the other nodes passes through the network, delays are
indistinguishable from failure. This is the fundamental problem of
the network partition: latency high enough to be considered a
failure. When partitions arise, we have no way to
determine what happened on the other nodes: are they alive?
Dead? Did they receive our message? Did they try to respond?
Literally no one knows. When the network finally heals, we'll
have to re-establish the connection and try to work out what
happened–perhaps recovering from an inconsistent state.”
-Kyle Kingsbury, Aphyr.com
What does 2600hz use?
• Cloudant BigCouch
• NoSQL Database
• Master-Master
• Very sensibly designed for our use case
Why BigCouch?
DEMANDS
1.On the Fly Schema Changes
2.Scale in a distributed fashion
3.Configuration changes will
happen as we grow
4.Has to be equipment
agnostic
5.Accessible Raw Data View
6.Simple to Install and Keep up
7.It can’t fail, ergo Fault-
Tolerance
8.Multi-Master writes
9.Simple (to cluster, to
TRADEOFFS
1.Eventual Consistency is OK
2.Nodes going offline randomly
3.Multi-server only
Why are we ok with these
tradeoffs? They suit our use
case.
Let’s take some time to pontificate about
Database at scale…
What are the first things you think of when
you get errors reported from the Database?
What’s your Thought Process?
• Database is where you put stuff
• You want your Database not to
die
• 2600hz uses BigCouch because
it’s really awesome technology
• Great for our Use Case
• Easy to Administrate
• Resilient and quick-to-restore
Recap
QUESTIONS???

More Related Content

What's hot

Bugs Aren't Random
Bugs Aren't RandomBugs Aren't Random
Bugs Aren't RandomDan Kaminsky
 
Distributed systems and consistency
Distributed systems and consistencyDistributed systems and consistency
Distributed systems and consistencyseldo
 
Error in hadoop
Error in hadoopError in hadoop
Error in hadoopLen Bass
 
Scaling Systems: Architectures that Grow
Scaling Systems: Architectures that GrowScaling Systems: Architectures that Grow
Scaling Systems: Architectures that GrowGibraltar Software
 
All you didn't know about the CAP theorem
All you didn't know about the CAP theoremAll you didn't know about the CAP theorem
All you didn't know about the CAP theoremKanstantsin Hontarau
 
A Technical Dive into Defensive Trickery
A Technical Dive into Defensive TrickeryA Technical Dive into Defensive Trickery
A Technical Dive into Defensive TrickeryDan Kaminsky
 
Architecting for the cloud elasticity security
Architecting for the cloud elasticity securityArchitecting for the cloud elasticity security
Architecting for the cloud elasticity securityLen Bass
 
Designing Events-First Microservices For A Cloud Native World
Designing Events-First Microservices For A Cloud Native WorldDesigning Events-First Microservices For A Cloud Native World
Designing Events-First Microservices For A Cloud Native WorldLightbend
 
devops, platforms and devops platforms
devops, platforms and devops platformsdevops, platforms and devops platforms
devops, platforms and devops platformsAndrew Shafer
 
2016 Mastering SAP Tech - 2 Speed IT and lessons from an Agile Waterfall eCom...
2016 Mastering SAP Tech - 2 Speed IT and lessons from an Agile Waterfall eCom...2016 Mastering SAP Tech - 2 Speed IT and lessons from an Agile Waterfall eCom...
2016 Mastering SAP Tech - 2 Speed IT and lessons from an Agile Waterfall eCom...Eneko Jon Bilbao
 
Scaling Systems: Architectures that grow
Scaling Systems: Architectures that growScaling Systems: Architectures that grow
Scaling Systems: Architectures that growGibraltar Software
 
Natural Laws of Software Performance
Natural Laws of Software PerformanceNatural Laws of Software Performance
Natural Laws of Software PerformanceGibraltar Software
 
From Divided to United - Aligning Technical and Business Teams
From Divided to United - Aligning Technical and Business TeamsFrom Divided to United - Aligning Technical and Business Teams
From Divided to United - Aligning Technical and Business TeamsDominica DeGrandis
 
Without Resilience, Nothing Else Matters
Without Resilience, Nothing Else MattersWithout Resilience, Nothing Else Matters
Without Resilience, Nothing Else MattersJonas Bonér
 
Architectural Tactics for Large Scale Systems
Architectural Tactics for Large Scale SystemsArchitectural Tactics for Large Scale Systems
Architectural Tactics for Large Scale SystemsLen Bass
 

What's hot (18)

Bugs Aren't Random
Bugs Aren't RandomBugs Aren't Random
Bugs Aren't Random
 
SQLDay2013_ChrisWebb_SSASDesignMistakes
SQLDay2013_ChrisWebb_SSASDesignMistakesSQLDay2013_ChrisWebb_SSASDesignMistakes
SQLDay2013_ChrisWebb_SSASDesignMistakes
 
Distributed systems and consistency
Distributed systems and consistencyDistributed systems and consistency
Distributed systems and consistency
 
Error in hadoop
Error in hadoopError in hadoop
Error in hadoop
 
Scaling Systems: Architectures that Grow
Scaling Systems: Architectures that GrowScaling Systems: Architectures that Grow
Scaling Systems: Architectures that Grow
 
All you didn't know about the CAP theorem
All you didn't know about the CAP theoremAll you didn't know about the CAP theorem
All you didn't know about the CAP theorem
 
A Technical Dive into Defensive Trickery
A Technical Dive into Defensive TrickeryA Technical Dive into Defensive Trickery
A Technical Dive into Defensive Trickery
 
Architecting for the cloud elasticity security
Architecting for the cloud elasticity securityArchitecting for the cloud elasticity security
Architecting for the cloud elasticity security
 
Designing Events-First Microservices For A Cloud Native World
Designing Events-First Microservices For A Cloud Native WorldDesigning Events-First Microservices For A Cloud Native World
Designing Events-First Microservices For A Cloud Native World
 
devops, platforms and devops platforms
devops, platforms and devops platformsdevops, platforms and devops platforms
devops, platforms and devops platforms
 
2016 Mastering SAP Tech - 2 Speed IT and lessons from an Agile Waterfall eCom...
2016 Mastering SAP Tech - 2 Speed IT and lessons from an Agile Waterfall eCom...2016 Mastering SAP Tech - 2 Speed IT and lessons from an Agile Waterfall eCom...
2016 Mastering SAP Tech - 2 Speed IT and lessons from an Agile Waterfall eCom...
 
CAP Theorem
CAP TheoremCAP Theorem
CAP Theorem
 
The CAP Theorem
The CAP Theorem The CAP Theorem
The CAP Theorem
 
Scaling Systems: Architectures that grow
Scaling Systems: Architectures that growScaling Systems: Architectures that grow
Scaling Systems: Architectures that grow
 
Natural Laws of Software Performance
Natural Laws of Software PerformanceNatural Laws of Software Performance
Natural Laws of Software Performance
 
From Divided to United - Aligning Technical and Business Teams
From Divided to United - Aligning Technical and Business TeamsFrom Divided to United - Aligning Technical and Business Teams
From Divided to United - Aligning Technical and Business Teams
 
Without Resilience, Nothing Else Matters
Without Resilience, Nothing Else MattersWithout Resilience, Nothing Else Matters
Without Resilience, Nothing Else Matters
 
Architectural Tactics for Large Scale Systems
Architectural Tactics for Large Scale SystemsArchitectural Tactics for Large Scale Systems
Architectural Tactics for Large Scale Systems
 

Similar to Database Expert Q&A from 2600hz and Cloudant

Cassandra Core Concepts - Cassandra Day Toronto
Cassandra Core Concepts - Cassandra Day TorontoCassandra Core Concepts - Cassandra Day Toronto
Cassandra Core Concepts - Cassandra Day TorontoJon Haddad
 
Cassandra Core Concepts
Cassandra Core ConceptsCassandra Core Concepts
Cassandra Core ConceptsJon Haddad
 
Distributed computing for new bloods
Distributed computing for new bloodsDistributed computing for new bloods
Distributed computing for new bloodsRaymond Tay
 
Modern Cloud Fundamentals: Misconceptions and Industry Trends
Modern Cloud Fundamentals: Misconceptions and Industry TrendsModern Cloud Fundamentals: Misconceptions and Industry Trends
Modern Cloud Fundamentals: Misconceptions and Industry TrendsChristopher Bennage
 
What's inside the black box? Using ML to tune and manage Kafka. (Matthew Stum...
What's inside the black box? Using ML to tune and manage Kafka. (Matthew Stum...What's inside the black box? Using ML to tune and manage Kafka. (Matthew Stum...
What's inside the black box? Using ML to tune and manage Kafka. (Matthew Stum...confluent
 
Scaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHPScaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHP120bi
 
Scaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsScaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsAchievers Tech
 
The Power of Determinism in Database Systems
The Power of Determinism in Database SystemsThe Power of Determinism in Database Systems
The Power of Determinism in Database SystemsDaniel Abadi
 
Relational and non relational database 7
Relational and non relational database 7Relational and non relational database 7
Relational and non relational database 7abdulrahmanhelan
 
Tiger oracle
Tiger oracleTiger oracle
Tiger oracled0nn9n
 
Storage Systems For Scalable systems
Storage Systems For Scalable systemsStorage Systems For Scalable systems
Storage Systems For Scalable systemselliando dias
 
Bridging the Developer and the Datacenter
Bridging the Developer and the DatacenterBridging the Developer and the Datacenter
Bridging the Developer and the Datacenterlurs83
 
Jay Kreps on Project Voldemort Scaling Simple Storage At LinkedIn
Jay Kreps on Project Voldemort Scaling Simple Storage At LinkedInJay Kreps on Project Voldemort Scaling Simple Storage At LinkedIn
Jay Kreps on Project Voldemort Scaling Simple Storage At LinkedInLinkedIn
 
Stig: Social Graphs & Discovery at Scale
Stig: Social Graphs & Discovery at ScaleStig: Social Graphs & Discovery at Scale
Stig: Social Graphs & Discovery at ScaleDATAVERSITY
 
Java in High Frequency Trading
Java in High Frequency TradingJava in High Frequency Trading
Java in High Frequency TradingViktor Sovietov
 
Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...
Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...
Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...DataStax
 
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...smallerror
 
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...xlight
 
Fixing twitter
Fixing twitterFixing twitter
Fixing twitterRoger Xia
 

Similar to Database Expert Q&A from 2600hz and Cloudant (20)

Cassandra Core Concepts - Cassandra Day Toronto
Cassandra Core Concepts - Cassandra Day TorontoCassandra Core Concepts - Cassandra Day Toronto
Cassandra Core Concepts - Cassandra Day Toronto
 
Cassandra Core Concepts
Cassandra Core ConceptsCassandra Core Concepts
Cassandra Core Concepts
 
Distributed computing for new bloods
Distributed computing for new bloodsDistributed computing for new bloods
Distributed computing for new bloods
 
Modern Cloud Fundamentals: Misconceptions and Industry Trends
Modern Cloud Fundamentals: Misconceptions and Industry TrendsModern Cloud Fundamentals: Misconceptions and Industry Trends
Modern Cloud Fundamentals: Misconceptions and Industry Trends
 
What's inside the black box? Using ML to tune and manage Kafka. (Matthew Stum...
What's inside the black box? Using ML to tune and manage Kafka. (Matthew Stum...What's inside the black box? Using ML to tune and manage Kafka. (Matthew Stum...
What's inside the black box? Using ML to tune and manage Kafka. (Matthew Stum...
 
Scaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHPScaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHP
 
Scaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsScaling High Traffic Web Applications
Scaling High Traffic Web Applications
 
The Power of Determinism in Database Systems
The Power of Determinism in Database SystemsThe Power of Determinism in Database Systems
The Power of Determinism in Database Systems
 
Relational and non relational database 7
Relational and non relational database 7Relational and non relational database 7
Relational and non relational database 7
 
Tiger oracle
Tiger oracleTiger oracle
Tiger oracle
 
Storage Systems For Scalable systems
Storage Systems For Scalable systemsStorage Systems For Scalable systems
Storage Systems For Scalable systems
 
Bridging the Developer and the Datacenter
Bridging the Developer and the DatacenterBridging the Developer and the Datacenter
Bridging the Developer and the Datacenter
 
Jay Kreps on Project Voldemort Scaling Simple Storage At LinkedIn
Jay Kreps on Project Voldemort Scaling Simple Storage At LinkedInJay Kreps on Project Voldemort Scaling Simple Storage At LinkedIn
Jay Kreps on Project Voldemort Scaling Simple Storage At LinkedIn
 
Stig: Social Graphs & Discovery at Scale
Stig: Social Graphs & Discovery at ScaleStig: Social Graphs & Discovery at Scale
Stig: Social Graphs & Discovery at Scale
 
Java in High Frequency Trading
Java in High Frequency TradingJava in High Frequency Trading
Java in High Frequency Trading
 
Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...
Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...
Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...
 
Cassandra Core Concepts
Cassandra Core ConceptsCassandra Core Concepts
Cassandra Core Concepts
 
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
 
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...Fixing Twitter  Improving The Performance And Scalability Of The Worlds Most ...
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
 
Fixing twitter
Fixing twitterFixing twitter
Fixing twitter
 

Recently uploaded

Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024TopCSSGallery
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS:  6 Ways to Automate Your Data IntegrationBridging Between CAD & GIS:  6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integrationmarketing932765
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observabilityitnewsafrica
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality AssuranceInflectra
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Mark Goldstein
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Nikki Chapple
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationKnoldus Inc.
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfpanagenda
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesMuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesManik S Magar
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI AgeCprime
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 

Recently uploaded (20)

Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS:  6 Ways to Automate Your Data IntegrationBridging Between CAD & GIS:  6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog Presentation
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesMuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI Age
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 

Database Expert Q&A from 2600hz and Cloudant

  • 1. Powerful, Distributed, API Communications Call-in Number: 513.386.0101Pin 705-705- 141 Expert Q&A: Database Edition May 31st , 2013
  • 3. Our Panelists Joshua Goldbard Marketing Ninja, 2600hz, Moderator Darren Schreiber Founder, 2600hz Sam Bisbee Cloudant
  • 4. Database: It’s all good until it isn’t
  • 6. What is Database? • A Record of things Remembered or Forgotten • Used to be Unbelievably hard, now it’s just hard sometimes • Modern Databases are amazingly resilient • Failure Mode still requires lots of attention • In Distributed Environments… • Database is inexorably linked to the network • The network is always unreliable if public
  • 7. Masters and Slaves • Databases have to Replicate • Most Databases use a form of Master-Slave Relationship to manage replication and dedupe • Masters are where new data is entered • Then it’s mirrored out to the Slaves for storage • If you lose access to the original Master, you can convert a Slave into a Master and restore operation Durability
  • 8. Other Replication Strategies • Other strategies exist, such as… • Master-Master (What 2600hz Uses) • Tokenized Exchange • Time-delimited • The most popular methods tend to be Master- Slave or Master-Master Each Database has its advantages and tradeoffs. Once again, there is no Magic Bullet.
  • 9. Failure and Quorum • When A Database needs to elect a new master… • There are many different strategies • Most involve the concept of quorum (figuring out where the greatest number of copies reside) • Once Quorum is established, a new master is elected and (hopefully) operation can resume • Quorum is different in Master-Master (Explain)
  • 10. Cap Theorem Databases can have (at most) 2 out of 3 of the following: •Consistency •Availability •Partition Tolerance Modern Database Management is balancing between Consistency and Availability because all modern networks are unreliable
  • 12. What is Important in a Database? • Reliable Storage of Data? • Fast Retrieval of Data? • Fast Saving of Data? • Resilience during failures? • <other>
  • 13. Examples • Buying tickets from ticketmaster • What’s important and why? • Withdrawing money from a bank? • Storing Call Forwarding Settings? • Storing a List of Favorite Stocks? Each Scenario has a different set of requirements and constraints. There is no silver bullet; if you could write one database for all these scenarios, you’d be rich.
  • 14. Which Database is Better? • STUPID QUESTION • But I thought there were no stupid questions? • This is the only stupid question. • The fight of which database is better is almost always silly • Databases are a tool, to get a job done • Like the previous examples, each job is different • Each database stresses different pros/cons
  • 16. Trouble With Databases • HUGE TOPIC (We’re only going to cover a little) • Network Partitions • Layer 1 disasters • Flapping Internet (Special Class of Network Partitions)
  • 17. Network Partitions • Common in Distributed Databases • When Databases lose contact with each other they can partition • Caused by unreliable or faulty network connections • Databases can behave very weirdly when in partitions Arguably, most of what a database admin does is prepare for network partitions and how to resolve them.
  • 20. Split-Brain • During a partition, some databases will elect N masters, one for each partition in the network. • When the partition is fixed, unless there is a pre-defined restoral procedure, there will be conflicts • Databases have all kinds of strategies for handling WAN Split- brain failure, but you should understand them Key Takeaway: No Database is perfect. Understand the automation but also understand the manual intervention procedure.
  • 22. Layer 1 Failures • Rut Roh • Actual Physical Disaster • No easy way out except… • Don’t be in a Datacenter that’s hit by a disaster OR • Be Nimble enough to Evade Disaster
  • 23. Evading Disaster • We’re not Magicians, we can’t simply predict disasters • The next best thing is being able to move and move fast • Kazoo requires one line of code to move • Kazoo moves fast • Moving the Database fast is awesome (Thanks BigCouch!) During Hurricane Sandy, we cut our Datacenters away from Downtown New York to a Datacenter above the 100 year flood plain on the East Coast. Result: No Downtime.
  • 24. No Silver Bullets • Layer 1 disasters are a humbling experience • Don’t rely on DataCenters in the Path of a Storm • Flooding will brick datacenters that have generators below ground • To avoid being powerless in a disaster… • Plan, Test, Analyze, Repeat • Check out Netflix Simian Army for examples of tests
  • 25. Flapping • Is it up? Is it Down? Around and Around it Goes, where it stops nobody knows… • Flapping Internet is a special case of network partition or lose connectivity • Flapping connections lose contact with other servers and then appear to come back online before going off Why is this bad?
  • 26. Fixing Flapping • I’m trying to fix a partition • The Network keeps going up and down • As I repair my cluster, it keeps starting to repair and failing (by attempting to reintegrate the unreliable nodes) Flapping nodes make everything awful
  • 27. Why is the Network Difficult? “Detecting network failures is hard. Since our only knowledge of the other nodes passes through the network, delays are indistinguishable from failure. This is the fundamental problem of the network partition: latency high enough to be considered a failure. When partitions arise, we have no way to determine what happened on the other nodes: are they alive? Dead? Did they receive our message? Did they try to respond? Literally no one knows. When the network finally heals, we'll have to re-establish the connection and try to work out what happened–perhaps recovering from an inconsistent state.” -Kyle Kingsbury, Aphyr.com
  • 28. Why is the Network Difficult? “Detecting network failures is hard. Since our only knowledge of the other nodes passes through the network, delays are indistinguishable from failure. This is the fundamental problem of the network partition: latency high enough to be considered a failure. When partitions arise, we have no way to determine what happened on the other nodes: are they alive? Dead? Did they receive our message? Did they try to respond? Literally no one knows. When the network finally heals, we'll have to re-establish the connection and try to work out what happened–perhaps recovering from an inconsistent state.” -Kyle Kingsbury, Aphyr.com
  • 29. Why is the Network Difficult? “Detecting network failures is hard. Since our only knowledge of the other nodes passes through the network, delays are indistinguishable from failure. This is the fundamental problem of the network partition: latency high enough to be considered a failure. When partitions arise, we have no way to determine what happened on the other nodes: are they alive? Dead? Did they receive our message? Did they try to respond? Literally no one knows. When the network finally heals, we'll have to re-establish the connection and try to work out what happened–perhaps recovering from an inconsistent state.” -Kyle Kingsbury, Aphyr.com
  • 30. What does 2600hz use? • Cloudant BigCouch • NoSQL Database • Master-Master • Very sensibly designed for our use case
  • 31. Why BigCouch? DEMANDS 1.On the Fly Schema Changes 2.Scale in a distributed fashion 3.Configuration changes will happen as we grow 4.Has to be equipment agnostic 5.Accessible Raw Data View 6.Simple to Install and Keep up 7.It can’t fail, ergo Fault- Tolerance 8.Multi-Master writes 9.Simple (to cluster, to TRADEOFFS 1.Eventual Consistency is OK 2.Nodes going offline randomly 3.Multi-server only Why are we ok with these tradeoffs? They suit our use case.
  • 32. Let’s take some time to pontificate about Database at scale… What are the first things you think of when you get errors reported from the Database? What’s your Thought Process?
  • 33. • Database is where you put stuff • You want your Database not to die • 2600hz uses BigCouch because it’s really awesome technology • Great for our Use Case • Easy to Administrate • Resilient and quick-to-restore Recap

Editor's Notes

  1. When do we come in and provide the support? Possile examples?
  2. Sponsered features?...they have access to current and future features for free.
  3. Sponsered features?...they have access to current and future features for free.
  4. Yealink stuff: make sure you send the right firmware and then the right config file. If you send the wrong config file, or send the file too early, you can brick the phone. 50 handsets is the threshold for DHCP66
  5. Trunks, license fees, connect remote offices
  6. I fell I need more info on this section…realm DNS