SlideShare uma empresa Scribd logo
1 de 36
Maciej Miara, April 2014
• Non-relational database model
• Easy horizontal scalability
• Different data structures:
- key-value store
- key-value cache
- object database
- document store
- graph store
- wide-column store
• Denormalization
•
•
•
•
•
•
•
Data structure
Data structure
•
•
Object ID
ObjectId("507f191e810c19729de860ea")
Seconds since
the Unix epoch
Machine
identifier
Process id
Counter, starts with
random value
•
•
•
•
Schema
•
•
•
Schema
Schema
Second query confirms, that mongo returns null,
when attribute is not found in document
•
•
Querying embedded data
Querying embedded data
•
•
•
•
db.createCollection("log", { capped : true, size : 5242880, max : 5000
} )
• Good for logs or temporary data
Capped collections
•
•
•
•
•
Map-Reduce
•
•
•
•
•
•
Indexes
•
•
•
•
Geospatial indexes
•
•
•
•
•
•
•
Geospatial queries
Geospatial queries - examples
Source:
http://docs.mongodb.org
•
•
•
•
•
•
Full text search
Full text search
Supported languages:
danish, dutch, english, finnish, french, german,
hungarian, italian, norwegian, portuguese, norwegian,
rommanian, russian, spanish, swedish, turkish
Source:
http://docs.mongodb.org
Sharding
•
•
•
•
Sharding
Source:
http://docs.mongodb.org
•
•
•
•
•
•
GridFS
•
•
•
•
Javascript driven
•
•
•
•
ACID
•
•
•
Transaction system
•
•
•
•
Journaling
•
•
•
•
•
Write concern
Unacknowledged
Source:
http://docs.mongodb.org
Acknowledged
Source:
http://docs.mongodb.org
Journal acknowledged
Source:
http://docs.mongodb.org
Replica acknowledged
Source:
http://docs.mongodb.org
Some people complain
about Mongo, but…
…they just don’t know,
why they chose it
• „My friend from studies used it”
• „I was just curious”
• „Recommended by other company
(in their project it worked well)”
• „Technical (!) client wanted it”
• „After all-night long party I decided
to use it”
• „I heard that
Microsoft/Google/NYT/(fill in any
corpo you want) uses it”
Do NOT use Mongo, if you:
• like joins
• Need really transactional system
• Have relational data
• Want full ACID without any
compromises
Any questions?
maciej.miara@gmail.com

Mais conteúdo relacionado

Mais procurados

Rails with MongoDB
Rails with MongoDBRails with MongoDB
Rails with MongoDB
Eugene Park
 

Mais procurados (13)

Asp.Net MVC
Asp.Net MVCAsp.Net MVC
Asp.Net MVC
 
Rails with MongoDB
Rails with MongoDBRails with MongoDB
Rails with MongoDB
 
Ruby onrails overview
Ruby onrails overviewRuby onrails overview
Ruby onrails overview
 
Multi-model database
Multi-model databaseMulti-model database
Multi-model database
 
Teradata QueryGrid to MongoDB Lightning Introduction
Teradata QueryGrid to MongoDB Lightning IntroductionTeradata QueryGrid to MongoDB Lightning Introduction
Teradata QueryGrid to MongoDB Lightning Introduction
 
Practical Use of a NoSQL Database
Practical Use of a NoSQL DatabasePractical Use of a NoSQL Database
Practical Use of a NoSQL Database
 
01 nosql and multi model database
01   nosql and multi model database01   nosql and multi model database
01 nosql and multi model database
 
Multi model-databases
Multi model-databasesMulti model-databases
Multi model-databases
 
#nosql introduction
#nosql introduction#nosql introduction
#nosql introduction
 
Multi model-databases 29-10-2014 LJC
Multi model-databases 29-10-2014 LJCMulti model-databases 29-10-2014 LJC
Multi model-databases 29-10-2014 LJC
 
MongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer GuideMongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer Guide
 
Webinar: Live Data Visualisation with Tableau and MongoDB
Webinar: Live Data Visualisation with Tableau and MongoDBWebinar: Live Data Visualisation with Tableau and MongoDB
Webinar: Live Data Visualisation with Tableau and MongoDB
 
MongoDB 3.2 Feature Preview
MongoDB 3.2 Feature PreviewMongoDB 3.2 Feature Preview
MongoDB 3.2 Feature Preview
 

Semelhante a mongoDB: Why it should (not) replace your SQL database?

Common MongoDB Use Cases
Common MongoDB Use Cases Common MongoDB Use Cases
Common MongoDB Use Cases
MongoDB
 
The Last Mile: Challenges and Opportunities in Data Tools (Strata 2014)
The Last Mile: Challenges and Opportunities in Data Tools (Strata 2014)The Last Mile: Challenges and Opportunities in Data Tools (Strata 2014)
The Last Mile: Challenges and Opportunities in Data Tools (Strata 2014)
DataPad Inc.
 
Data Mining With SQL Server
Data Mining With SQL ServerData Mining With SQL Server
Data Mining With SQL Server
Hoan Phuc
 

Semelhante a mongoDB: Why it should (not) replace your SQL database? (20)

Mongo DB
Mongo DB Mongo DB
Mongo DB
 
MongoDB & NoSQL 101
 MongoDB & NoSQL 101 MongoDB & NoSQL 101
MongoDB & NoSQL 101
 
9. Document Oriented Databases
9. Document Oriented Databases9. Document Oriented Databases
9. Document Oriented Databases
 
Common MongoDB Use Cases
Common MongoDB Use Cases Common MongoDB Use Cases
Common MongoDB Use Cases
 
MongoDB
MongoDBMongoDB
MongoDB
 
Document db
Document dbDocument db
Document db
 
The Last Mile: Challenges and Opportunities in Data Tools (Strata 2014)
The Last Mile: Challenges and Opportunities in Data Tools (Strata 2014)The Last Mile: Challenges and Opportunities in Data Tools (Strata 2014)
The Last Mile: Challenges and Opportunities in Data Tools (Strata 2014)
 
Serverless SQL
Serverless SQLServerless SQL
Serverless SQL
 
Data as Documents: Overview and intro to MongoDB
Data as Documents: Overview and intro to MongoDBData as Documents: Overview and intro to MongoDB
Data as Documents: Overview and intro to MongoDB
 
Rdbms
RdbmsRdbms
Rdbms
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
 
AzureSynapse.pptx
AzureSynapse.pptxAzureSynapse.pptx
AzureSynapse.pptx
 
An Evening with MongoDB - Orlando: Welcome and Keynote
An Evening with MongoDB - Orlando: Welcome and KeynoteAn Evening with MongoDB - Orlando: Welcome and Keynote
An Evening with MongoDB - Orlando: Welcome and Keynote
 
CRM UG Belux March 2017 - Power BI and Dynamics 365
CRM UG Belux March 2017 - Power BI and Dynamics 365CRM UG Belux March 2017 - Power BI and Dynamics 365
CRM UG Belux March 2017 - Power BI and Dynamics 365
 
A Presentation on MongoDB Introduction - Habilelabs
A Presentation on MongoDB Introduction - HabilelabsA Presentation on MongoDB Introduction - Habilelabs
A Presentation on MongoDB Introduction - Habilelabs
 
Webinar - Macy’s: Why Your Database Decision Directly Impacts Customer Experi...
Webinar - Macy’s: Why Your Database Decision Directly Impacts Customer Experi...Webinar - Macy’s: Why Your Database Decision Directly Impacts Customer Experi...
Webinar - Macy’s: Why Your Database Decision Directly Impacts Customer Experi...
 
Agility and Scalability with MongoDB
Agility and Scalability with MongoDBAgility and Scalability with MongoDB
Agility and Scalability with MongoDB
 
Test driving Azure Search and DocumentDB
Test driving Azure Search and DocumentDBTest driving Azure Search and DocumentDB
Test driving Azure Search and DocumentDB
 
Data Mining With SQL Server
Data Mining With SQL ServerData Mining With SQL Server
Data Mining With SQL Server
 
Webinar Slides: Tungsten Replicator for Elasticsearch - Real-time data loadin...
Webinar Slides: Tungsten Replicator for Elasticsearch - Real-time data loadin...Webinar Slides: Tungsten Replicator for Elasticsearch - Real-time data loadin...
Webinar Slides: Tungsten Replicator for Elasticsearch - Real-time data loadin...
 

Último

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Último (20)

ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
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
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
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
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 

mongoDB: Why it should (not) replace your SQL database?