SlideShare ist ein Scribd-Unternehmen logo
1 von 34
Downloaden Sie, um offline zu lesen
POLYGLOT
PERSISTENCE
alex brandt
sr developer
Wednesday, August 21, 13
2
Wednesday, August 21, 13
3
Wednesday, August 21, 13
4
Wednesday, August 21, 13
5
RDBMS may not be the best fit
Wednesday, August 21, 13
6
Wednesday, August 21, 13
7
Wednesday, August 21, 13
INTRODUCTION TO
NOSQL
• NoSQL Database (1998)
• NoREL
• “Not only SQL”
• NoSQL (2009)
8
Wednesday, August 21, 13
9
5 Characteristics
Wednesday, August 21, 13
10
Non-relational
Wednesday, August 21, 13
11
Distributed
Wednesday, August 21, 13
12
Open-source
Wednesday, August 21, 13
13
Horizontally Scalable
Wednesday, August 21, 13
14
Schema-less
Wednesday, August 21, 13
orders
customers
order lines
credit cards
ID: 1001
line items:
customer: Ann
0321293533
0321601912
0131495054
2
1
1
$48 $48
$39
$51
$39
$51
payment details:
Card: Amex
CC #: 12345
expires: 04/2001
15
Wednesday, August 21, 13
16
Types in Detail
Wednesday, August 21, 13
Key/Value DatabaseS
17
Wednesday, August 21, 13
Key/Value DatabaseS
• Good Use Cases:
• Storing Session Information
• User Profiles & Preferences
• Shopping Cart Data
• Bad Use Cases:
• Data Relationships
•Multi-operation Transactions
•Query by Data
18
Wednesday, August 21, 13
Key/Value DatabaseS
• Good Use Cases:
• Storing Session Information
• User Profiles & Preferences
• Shopping Cart Data
• Bad Use Cases:
• Data Relationships
•Multi-operation Transactions
•Query by Data
19
Wednesday, August 21, 13
document Database
20
Wednesday, August 21, 13
document Databases
•Good Use Cases:
• Event Logging
• Blogging Platforms
• Real-time Analytics
• Article storage
• Bad Use Cases:
• Complex Transactions
•Queries against Varying
Aggregate Structures
21
Wednesday, August 21, 13
document Databases
•Good Use Cases:
• Event Logging
• Blogging Platforms
• Real-time Analytics
• Article storage
• Bad Use Cases:
• Complex Transactions
•Queries against Varying
Aggregate Structures
22
Wednesday, August 21, 13
COLUMN FAMILY
23
Wednesday, August 21, 13
24
Wednesday, August 21, 13
COLUMN-FAMILY
datastores
•Good Use Cases:
• Event Logging
• Blogging Platforms
• Counters (page visits)
• Expiring Usage
• Bad Use Cases:
• ACID transactions
required
• Early prototype
applications
25
Wednesday, August 21, 13
graph database
26
Wednesday, August 21, 13
Amanda
KNOWS
KNOWS
KNOWS
Robert
Gerry
Lamar
KNOWS
App 1
BUILT
BUILT
KNOWS
App 2
USES
BUILT
Christie
KNOWS
Destiny
Jessica
KNOWS
App 3
BUILT
USES
USES
USES
KNOWS
graph database
27
Wednesday, August 21, 13
graph databases
•Good Use Cases:
• Connected Data
• Location-based services
• Recommendation engines
• Bad Use Cases:
• Ability to update
specific aggregates
28
Wednesday, August 21, 13
Companies using
nosql
29
DATABASE COMPANIES
Wednesday, August 21, 13
THE FUTURE IS POLYGLOT
30
Neo4J
database
Cassandra
database
Couch
database
MongoDB
database
RELATIONAL
DATABASE
Graph-structured
domain rules
Columnar data
access with
decentralization
Document
structures
Document structures
with offline
processing
(Actors) (Actors)
(Actors)(Actors)
Asynchronous message passing
MODULE 1
MODULE 2
MODULE 3
MODULE 4
IEEE Software Sept/October 2010 - Debasish Ghosh / Twitter @debasishg
Wednesday, August 21, 13
31
POLYGLOT PATTERN: cache
ORDER
TAKING
RESTAURANT
MANAGEMENT
REDIS
CACHE
MYSQL
DATABASE
SECONDFIRST
CONSUMER
RESTAURANT
OWNER
Credit: @crichardson
Wednesday, August 21, 13
32
POLYGLOT PATTERN:
write to sql and NOSQL
NEW
TWEET
INSERT
LPUSHX
LTRIM
MySQL
TWEETS
FOLLOWS
FOLLOWERS
Redis: Timeline
FOLLOWER 1
FOLLOWER 2
FOLLOWER 3
Avoid
expensive
MySQL joins
Credit: @crichardson
Wednesday, August 21, 13
33
POLYGLOT PATTERN:
REPLICATE FROM
MYsql to NOSQL
QUERY
SERVICE
UPDATE
SERVICE
REDIS
MYSQL
DATABASE
SYSTEM
OF
RECORD
MATERIALIZED
VIEW
READER WRITER
replicate and
denormalize
query() update()
Credit: @crichardson
Wednesday, August 21, 13
34
Atomic
Consistent
Isolated
Durable
ACID to base
Basically Available
Soft state
Eventually consistent
Wednesday, August 21, 13

Weitere ähnliche Inhalte

Andere mochten auch

Enterprise Cloud Forum Rackspace IT: Journey to the Cloud
Enterprise Cloud Forum Rackspace IT: Journey to the CloudEnterprise Cloud Forum Rackspace IT: Journey to the Cloud
Enterprise Cloud Forum Rackspace IT: Journey to the Cloud
Rackspace
 
Top 8 assistant general manager hotel resume samples
Top 8 assistant general manager hotel resume samplesTop 8 assistant general manager hotel resume samples
Top 8 assistant general manager hotel resume samples
jomsgue
 
Jason Pannell Resume
Jason Pannell ResumeJason Pannell Resume
Jason Pannell Resume
Jason Pannell
 
Making Sense of NoSQL and Big Data Amidst High Expectations
Making Sense of NoSQL and Big Data Amidst High ExpectationsMaking Sense of NoSQL and Big Data Amidst High Expectations
Making Sense of NoSQL and Big Data Amidst High Expectations
Rackspace
 
Straight Up Startup…Featuring Eli Rosenberg, COO & Co-Founder of Food Genius
Straight Up Startup…Featuring Eli Rosenberg, COO & Co-Founder of Food GeniusStraight Up Startup…Featuring Eli Rosenberg, COO & Co-Founder of Food Genius
Straight Up Startup…Featuring Eli Rosenberg, COO & Co-Founder of Food Genius
Rackspace
 

Andere mochten auch (11)

Enterprise Cloud Forum Rackspace IT: Journey to the Cloud
Enterprise Cloud Forum Rackspace IT: Journey to the CloudEnterprise Cloud Forum Rackspace IT: Journey to the Cloud
Enterprise Cloud Forum Rackspace IT: Journey to the Cloud
 
Scaling Xen Within Rackspace Cloud Servers
Scaling Xen Within Rackspace Cloud ServersScaling Xen Within Rackspace Cloud Servers
Scaling Xen Within Rackspace Cloud Servers
 
Top 8 assistant general manager hotel resume samples
Top 8 assistant general manager hotel resume samplesTop 8 assistant general manager hotel resume samples
Top 8 assistant general manager hotel resume samples
 
vSphere with Openstack
vSphere with OpenstackvSphere with Openstack
vSphere with Openstack
 
Jason Pannell Resume
Jason Pannell ResumeJason Pannell Resume
Jason Pannell Resume
 
Making Sense of NoSQL and Big Data Amidst High Expectations
Making Sense of NoSQL and Big Data Amidst High ExpectationsMaking Sense of NoSQL and Big Data Amidst High Expectations
Making Sense of NoSQL and Big Data Amidst High Expectations
 
Behind The Scenes: New Rackspace Cloud Control Panel
Behind The Scenes:  New Rackspace Cloud Control PanelBehind The Scenes:  New Rackspace Cloud Control Panel
Behind The Scenes: New Rackspace Cloud Control Panel
 
Straight Up Startup…Featuring Eli Rosenberg, COO & Co-Founder of Food Genius
Straight Up Startup…Featuring Eli Rosenberg, COO & Co-Founder of Food GeniusStraight Up Startup…Featuring Eli Rosenberg, COO & Co-Founder of Food Genius
Straight Up Startup…Featuring Eli Rosenberg, COO & Co-Founder of Food Genius
 
Rackspace::Solve NYC - Solving for Rapid Customer Growth and Scale Through De...
Rackspace::Solve NYC - Solving for Rapid Customer Growth and Scale Through De...Rackspace::Solve NYC - Solving for Rapid Customer Growth and Scale Through De...
Rackspace::Solve NYC - Solving for Rapid Customer Growth and Scale Through De...
 
RMS Security Breakfast
RMS Security BreakfastRMS Security Breakfast
RMS Security Breakfast
 
6 Commonly Asked Questions from Customers Building on AWS
6 Commonly Asked Questions from Customers Building on AWS6 Commonly Asked Questions from Customers Building on AWS
6 Commonly Asked Questions from Customers Building on AWS
 

Ähnlich wie Polyglot Persistence

Unlocked London - Technical Track
Unlocked London - Technical TrackUnlocked London - Technical Track
Unlocked London - Technical Track
Wayne Walls
 
The data model is dead, long live the data model
The data model is dead, long live the data modelThe data model is dead, long live the data model
The data model is dead, long live the data model
Patrick McFadin
 

Ähnlich wie Polyglot Persistence (13)

Unlocked London - Technical Track
Unlocked London - Technical TrackUnlocked London - Technical Track
Unlocked London - Technical Track
 
Building Antifragile Applications with Apache Cassandra
Building Antifragile Applications with Apache CassandraBuilding Antifragile Applications with Apache Cassandra
Building Antifragile Applications with Apache Cassandra
 
Cassandra at scale
Cassandra at scaleCassandra at scale
Cassandra at scale
 
SQL vs. NoSQL. It's always a hard choice.
SQL vs. NoSQL. It's always a hard choice.SQL vs. NoSQL. It's always a hard choice.
SQL vs. NoSQL. It's always a hard choice.
 
Making the Switch, Part 1: Top 5 Things to Consider When Evaluating Drupal
Making the Switch, Part 1: Top 5 Things to Consider When Evaluating DrupalMaking the Switch, Part 1: Top 5 Things to Consider When Evaluating Drupal
Making the Switch, Part 1: Top 5 Things to Consider When Evaluating Drupal
 
Couchbase 3.0.2 d1
Couchbase 3.0.2  d1Couchbase 3.0.2  d1
Couchbase 3.0.2 d1
 
Semi Formal Model for Document Oriented Databases
Semi Formal Model for Document Oriented DatabasesSemi Formal Model for Document Oriented Databases
Semi Formal Model for Document Oriented Databases
 
Crafting Solutions with the Elastic Stack: pragmatic takes and lessons learned
Crafting Solutions with the Elastic Stack: pragmatic takes and lessons learnedCrafting Solutions with the Elastic Stack: pragmatic takes and lessons learned
Crafting Solutions with the Elastic Stack: pragmatic takes and lessons learned
 
Mongo db
Mongo dbMongo db
Mongo db
 
What can we learn from NoSQL technologies?
What can we learn from NoSQL technologies?What can we learn from NoSQL technologies?
What can we learn from NoSQL technologies?
 
Introduction to Riak - Joel Jacobson
Introduction to Riak - Joel JacobsonIntroduction to Riak - Joel Jacobson
Introduction to Riak - Joel Jacobson
 
The data model is dead, long live the data model
The data model is dead, long live the data modelThe data model is dead, long live the data model
The data model is dead, long live the data model
 
Prague data management meetup 2018-02-27
Prague data management meetup 2018-02-27Prague data management meetup 2018-02-27
Prague data management meetup 2018-02-27
 

Mehr von Wayne Walls

HubSpot Case Study
HubSpot Case StudyHubSpot Case Study
HubSpot Case Study
Wayne Walls
 
Everything as Code
Everything as CodeEverything as Code
Everything as Code
Wayne Walls
 
Cloudify Your Business
Cloudify Your BusinessCloudify Your Business
Cloudify Your Business
Wayne Walls
 
The 5 Pillars of Cloudiness
The 5 Pillars of CloudinessThe 5 Pillars of Cloudiness
The 5 Pillars of Cloudiness
Wayne Walls
 
Unlocked Workshop OSCON 2013 - Part II
Unlocked Workshop OSCON 2013 - Part IIUnlocked Workshop OSCON 2013 - Part II
Unlocked Workshop OSCON 2013 - Part II
Wayne Walls
 
Unlocked London - General Session
Unlocked London - General SessionUnlocked London - General Session
Unlocked London - General Session
Wayne Walls
 
Unlocked London - Case Studies
Unlocked London - Case StudiesUnlocked London - Case Studies
Unlocked London - Case Studies
Wayne Walls
 

Mehr von Wayne Walls (9)

HubSpot Case Study
HubSpot Case StudyHubSpot Case Study
HubSpot Case Study
 
Everything as Code
Everything as CodeEverything as Code
Everything as Code
 
Cloudify Your Business
Cloudify Your BusinessCloudify Your Business
Cloudify Your Business
 
The 5 Pillars of Cloudiness
The 5 Pillars of CloudinessThe 5 Pillars of Cloudiness
The 5 Pillars of Cloudiness
 
Unlocked Workshop OSCON 2013 - Part II
Unlocked Workshop OSCON 2013 - Part IIUnlocked Workshop OSCON 2013 - Part II
Unlocked Workshop OSCON 2013 - Part II
 
Unlocked London - General Session
Unlocked London - General SessionUnlocked London - General Session
Unlocked London - General Session
 
Unlocked London - Case Studies
Unlocked London - Case StudiesUnlocked London - Case Studies
Unlocked London - Case Studies
 
Agile-Techture: Nimble Cloud Engineering at Rackspace
Agile-Techture:  Nimble Cloud Engineering at RackspaceAgile-Techture:  Nimble Cloud Engineering at Rackspace
Agile-Techture: Nimble Cloud Engineering at Rackspace
 
Cloud Technology Stack Comparison (OpenStack) - Cloud Connect Chicago 2012
Cloud Technology Stack Comparison (OpenStack) - Cloud Connect Chicago 2012Cloud Technology Stack Comparison (OpenStack) - Cloud Connect Chicago 2012
Cloud Technology Stack Comparison (OpenStack) - Cloud Connect Chicago 2012
 

Kürzlich hochgeladen

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Kürzlich hochgeladen (20)

Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
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
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 

Polyglot Persistence