SlideShare a Scribd company logo
Web Data Management, Search and Retrieval Course (MCOM7348)
University of Birzeit, Palestine
January, 2014

Synthesis Paper Talk

Nosql Database
Fayez shayeb

bbbbb

Master of Computing, Birzeit University
Fayez.aauj@hotmail.com

Master of Computing, Birzeit University
bbbbbbb@yahoo.com

This is a student talk, at the Web Data Management, Search and Retrieval
Course, each student is is asked to present his/her synthesis paper.
Course Page: http://jarrar-courses.blogspot.com/2013/11/web-data-management.html
1
Document-oriented database
• document-oriented database is a computer
program designed for storing, retrieving, and
managing document-oriented, or semi structured
data, information
Comparison
 Document db

 Relational
Article
- id
- authorid
- title
- content

Author
- id
- name
- email

Comment
- id
- articleid
- message

Article
- _id
- title
- content
- author
- _id
- name
- email
- comments[]
Concepts
 Joins
 No joins
 Joins at "design time", not at "query time“
 Due to embedded docs and arrays less joins are needed

 Constraints
 No foreign key constraints
 Unique indexes

 Transactions
 No commit/rollback
 Atomic operations
 Multiple actions inside the same document
 Incl. embedded documents
Benefits

 Scalable: good for a lot of data / traffic
 Horizontal scaling: to more nodes
 Good for web-apps

 Performance
 No joins and constraints

 Dev/user friendly
 Data is modeled to how the app is going to use it
 No conversion between object oriented > relational
 No static schema = agile
One-to-many
 Embedded array / array keys
 Some queries get harder
 You can index arrays!

 Normalized approach
 More flexibility
 A lot less performance

Article
- _id
- content
- tags: {“foo”, “bar”}
- comments: {“id1”, “id2”}
many-to-many
 Using array keys
 No join table
 References on both sides
Article
- _id
- content
- category_ids : {“id1”, “id2”}

Category
- _id
- name
- article_ids: {“id7”, “id8”}

 Advantage: simple queries
articles.Where(p => p.CategoryIds.Contains(categoryId))
categories.Where(c => c.ArticleIds.Contains(articleId))

 Disadvantage: duplication, update two docs
json

•
•
•

Stands for Javascript Object Notation
Derived from Javascript scripting language
Used for representing simple data
structures and associative arrays

{

{
"_id": "BCCD12CBB",
"type": "person",
"name": "Darth Vader",
"age": 63,
"headware":
["Helmet", "Sombrero"],
"dark_side": true

}

"_id": "BCCD12CBC",
"type": "person",
"name": "Luke",
"age": 35,
"powers":
["Pull", "Jedi Mind Trick"],
"dark_side": false
}
Replication
 Only one server is active for writes (the primary, or

master) at a given time – this is to allow strong
consistent (atomic) operations. One can optionally
send read operations to the secondaries when
eventual consistency semantics are acceptable.
Sharding
 Sharding is the partitioning of data among multiple

machines in an order-preserving manner.(horizontal
scaling )
Machine 1

Machine 2

Machine 3

Alabama → Arizona

Colorado → Florida

Arkansas → California

Indiana → Kansas

Idaho → Illinois

Georgia → Hawaii

Maryland → Michigan

Kentucky → Maine

Minnesota → Missouri

Montana → Montana

Nebraska → New Jersey

Ohio → Pennsylvania

New Mexico → North Dakota

Rhode Island → South Dakota

Tennessee → Utah

Vermont → West Virgina

Wisconsin → Wyoming
Sharding
 The set of servers/mongod process within the shard

comprise a replica set
Replication & Sharding conclusion
 sharding is the tool for scaling a system, and

replication is the tool for data safety, high availability,
and disaster recovery. The two work in tandem yet are
orthogonal concepts in the design.
Document Databases
What is MongoDB?
 Creator: 10 gen, former doublick
 Name: short for humongous (
 Language: C++

)
What is MongoDB?
 Defination: MongoDB is an open source, document-

oriented database designed with both scalability and
developer agility in mind. Instead of storing your data
in tables and rows as you would with a relational
database, in MongoDB you store JSON-like
documents with dynamic schemas(schemafree, schemaless).
What is MongoDB?
 Goal: bridge the gap between key-value stores (which

are fast and scalable) and relational databases (which
have rich functionality).
MongoDB terms ?
Term mapping
MongoDB Data model
 Data model: Using BSON (binary JSON), developers

can easily map to modern object-oriented languages
without a complicated ORM layer.
 BSON is a binary format in which zero or more
key/value pairs are stored as a single entity.
 lightweight, traversable, efficient
Schema design
 RDBMS: join
Schema design
Schema design
Query MongoDB Vs sql?
SQL

mongodb

Create table

db.CreateCollection()

Insert into

db.coll.save()

select

db.coll.find()

update

db.coll.update

delete

db.coll.remove()

drop

db.coll.drop()
Query MongoDB Vs sql?
Query MongoDB Vs sql?
API for MongoDB :
C
C++
C#
Erlang
Haskell
Java
node.js

PHP
Perl
Python
Ruby
Scala (Casbah)
Thank You

27

More Related Content

What's hot

MongoDB: An Introduction - june-2011
MongoDB:  An Introduction - june-2011MongoDB:  An Introduction - june-2011
MongoDB: An Introduction - june-2011
Chris Westin
 
MongoDB NoSQL database a deep dive -MyWhitePaper
MongoDB  NoSQL database a deep dive -MyWhitePaperMongoDB  NoSQL database a deep dive -MyWhitePaper
MongoDB NoSQL database a deep dive -MyWhitePaper
Rajesh Kumar
 
An introduction to MongoDB
An introduction to MongoDBAn introduction to MongoDB
An introduction to MongoDB
César Trigo
 
MongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer GuideMongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer Guide
Shiv K Sah
 
MongoDB Schema Design by Examples
MongoDB Schema Design by ExamplesMongoDB Schema Design by Examples
MongoDB Schema Design by Examples
Hadi Ariawan
 
MongoDB presentation
MongoDB presentationMongoDB presentation
MongoDB presentation
Hyphen Call
 
Mongodb
MongodbMongodb
MongodB Internals
MongodB InternalsMongodB Internals
MongodB Internals
Norberto Leite
 
Mongo db report
Mongo db reportMongo db report
Mongo db report
Hyphen Call
 
Basics of MongoDB
Basics of MongoDB Basics of MongoDB
Basics of MongoDB
Habilelabs
 
MongoDB by Emroz sardar.
MongoDB by Emroz sardar.MongoDB by Emroz sardar.
MongoDB by Emroz sardar.
Emroz Sardar
 
Mongodb tutorial at Easylearning Guru
Mongodb tutorial  at Easylearning GuruMongodb tutorial  at Easylearning Guru
Mongodb tutorial at Easylearning Guru
KCC Software Ltd. & Easylearning.guru
 
A Study on Mongodb Database
A Study on Mongodb DatabaseA Study on Mongodb Database
A Study on Mongodb Database
IJSRD
 
Mongo DB: Operational Big Data Database
Mongo DB: Operational Big Data DatabaseMongo DB: Operational Big Data Database
Mongo DB: Operational Big Data Database
Xpand IT
 
Mongo DB
Mongo DBMongo DB
Introduction to mongodb
Introduction to mongodbIntroduction to mongodb
Introduction to mongodb
neela madheswari
 
Object oriented databases
Object oriented databasesObject oriented databases
Object oriented databases
Sajith Ekanayaka
 
SURVEY ON MONGODB: AN OPEN-SOURCE DOCUMENT DATABASE
SURVEY ON MONGODB: AN OPEN-SOURCE DOCUMENT DATABASESURVEY ON MONGODB: AN OPEN-SOURCE DOCUMENT DATABASE
SURVEY ON MONGODB: AN OPEN-SOURCE DOCUMENT DATABASE
IAEME Publication
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
Mike Dirolf
 
introduction to NOSQL Database
introduction to NOSQL Databaseintroduction to NOSQL Database
introduction to NOSQL Database
nehabsairam
 

What's hot (20)

MongoDB: An Introduction - june-2011
MongoDB:  An Introduction - june-2011MongoDB:  An Introduction - june-2011
MongoDB: An Introduction - june-2011
 
MongoDB NoSQL database a deep dive -MyWhitePaper
MongoDB  NoSQL database a deep dive -MyWhitePaperMongoDB  NoSQL database a deep dive -MyWhitePaper
MongoDB NoSQL database a deep dive -MyWhitePaper
 
An introduction to MongoDB
An introduction to MongoDBAn introduction to MongoDB
An introduction to MongoDB
 
MongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer GuideMongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer Guide
 
MongoDB Schema Design by Examples
MongoDB Schema Design by ExamplesMongoDB Schema Design by Examples
MongoDB Schema Design by Examples
 
MongoDB presentation
MongoDB presentationMongoDB presentation
MongoDB presentation
 
Mongodb
MongodbMongodb
Mongodb
 
MongodB Internals
MongodB InternalsMongodB Internals
MongodB Internals
 
Mongo db report
Mongo db reportMongo db report
Mongo db report
 
Basics of MongoDB
Basics of MongoDB Basics of MongoDB
Basics of MongoDB
 
MongoDB by Emroz sardar.
MongoDB by Emroz sardar.MongoDB by Emroz sardar.
MongoDB by Emroz sardar.
 
Mongodb tutorial at Easylearning Guru
Mongodb tutorial  at Easylearning GuruMongodb tutorial  at Easylearning Guru
Mongodb tutorial at Easylearning Guru
 
A Study on Mongodb Database
A Study on Mongodb DatabaseA Study on Mongodb Database
A Study on Mongodb Database
 
Mongo DB: Operational Big Data Database
Mongo DB: Operational Big Data DatabaseMongo DB: Operational Big Data Database
Mongo DB: Operational Big Data Database
 
Mongo DB
Mongo DBMongo DB
Mongo DB
 
Introduction to mongodb
Introduction to mongodbIntroduction to mongodb
Introduction to mongodb
 
Object oriented databases
Object oriented databasesObject oriented databases
Object oriented databases
 
SURVEY ON MONGODB: AN OPEN-SOURCE DOCUMENT DATABASE
SURVEY ON MONGODB: AN OPEN-SOURCE DOCUMENT DATABASESURVEY ON MONGODB: AN OPEN-SOURCE DOCUMENT DATABASE
SURVEY ON MONGODB: AN OPEN-SOURCE DOCUMENT DATABASE
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
 
introduction to NOSQL Database
introduction to NOSQL Databaseintroduction to NOSQL Database
introduction to NOSQL Database
 

Viewers also liked

MapReduce and Hadoop
MapReduce and HadoopMapReduce and Hadoop
MapReduce and Hadoop
Nicola Cadenelli
 
Visiting card
Visiting cardVisiting card
Visiting card
sriramanaexports
 
February Corporate Presentation 2014
February Corporate Presentation 2014February Corporate Presentation 2014
February Corporate Presentation 2014
oncolyticsinc
 
たのしいかめらのえらびかた~デジタル一眼編
たのしいかめらのえらびかた~デジタル一眼編たのしいかめらのえらびかた~デジタル一眼編
たのしいかめらのえらびかた~デジタル一眼編
Kegani
 
Ano 2013 retrospctiva
Ano 2013 retrospctivaAno 2013 retrospctiva
Ano 2013 retrospctiva
Andrea Ferreira Silva
 
Chamomiletea metroblog com_the_benefits_of_chamomile_tea
Chamomiletea metroblog com_the_benefits_of_chamomile_teaChamomiletea metroblog com_the_benefits_of_chamomile_tea
Chamomiletea metroblog com_the_benefits_of_chamomile_tea
Deloris Cooper
 
Quick Finance for Defaulters
Quick Finance for DefaultersQuick Finance for Defaulters
Quick Finance for Defaulters
Calvin Baird
 
Montes de Toledo
Montes de ToledoMontes de Toledo
Montes de Toledo
mjuanalcaide
 
SM_PPT_Example
SM_PPT_ExampleSM_PPT_Example
SM_PPT_Example
Katherine Bohren
 
Satélites artificiais
Satélites artificiaisSatélites artificiais
Satélites artificiaisnondoufeito
 
Cantabrian mountains
Cantabrian mountains Cantabrian mountains
Cantabrian mountains
mjuanalcaide
 
Preparation and contest
Preparation and contestPreparation and contest
Preparation and contest
msukms
 
Basque mountain
Basque mountain Basque mountain
Basque mountain
mjuanalcaide
 
GelecekHane Ticaret 2.0 - Mark Holenstein Sap
GelecekHane Ticaret 2.0 - Mark Holenstein SapGelecekHane Ticaret 2.0 - Mark Holenstein Sap
GelecekHane Ticaret 2.0 - Mark Holenstein Sap
Gelecek Hane
 
1 1
1 11 1
1 1
msukms
 
Evaluation for preliminary task
Evaluation for preliminary taskEvaluation for preliminary task
Evaluation for preliminary task
AliciaRhodes11
 
yOS tour de Montréal
yOS tour de MontréalyOS tour de Montréal
yOS tour de Montréal
Luc Labelle
 
ITFT - Famous wild life sancturies
ITFT - Famous wild life sancturiesITFT - Famous wild life sancturies
ITFT - Famous wild life sancturies
Anuj Tomar
 
Iberian mountain
Iberian mountainIberian mountain
Iberian mountain
mjuanalcaide
 

Viewers also liked (20)

MapReduce and Hadoop
MapReduce and HadoopMapReduce and Hadoop
MapReduce and Hadoop
 
Visiting card
Visiting cardVisiting card
Visiting card
 
February Corporate Presentation 2014
February Corporate Presentation 2014February Corporate Presentation 2014
February Corporate Presentation 2014
 
たのしいかめらのえらびかた~デジタル一眼編
たのしいかめらのえらびかた~デジタル一眼編たのしいかめらのえらびかた~デジタル一眼編
たのしいかめらのえらびかた~デジタル一眼編
 
Ano 2013 retrospctiva
Ano 2013 retrospctivaAno 2013 retrospctiva
Ano 2013 retrospctiva
 
Chamomiletea metroblog com_the_benefits_of_chamomile_tea
Chamomiletea metroblog com_the_benefits_of_chamomile_teaChamomiletea metroblog com_the_benefits_of_chamomile_tea
Chamomiletea metroblog com_the_benefits_of_chamomile_tea
 
Quick Finance for Defaulters
Quick Finance for DefaultersQuick Finance for Defaulters
Quick Finance for Defaulters
 
Montes de Toledo
Montes de ToledoMontes de Toledo
Montes de Toledo
 
SM_PPT_Example
SM_PPT_ExampleSM_PPT_Example
SM_PPT_Example
 
Satélites artificiais
Satélites artificiaisSatélites artificiais
Satélites artificiais
 
Cantabrian mountains
Cantabrian mountains Cantabrian mountains
Cantabrian mountains
 
Preparation and contest
Preparation and contestPreparation and contest
Preparation and contest
 
Cadde spot site
Cadde spot siteCadde spot site
Cadde spot site
 
Basque mountain
Basque mountain Basque mountain
Basque mountain
 
GelecekHane Ticaret 2.0 - Mark Holenstein Sap
GelecekHane Ticaret 2.0 - Mark Holenstein SapGelecekHane Ticaret 2.0 - Mark Holenstein Sap
GelecekHane Ticaret 2.0 - Mark Holenstein Sap
 
1 1
1 11 1
1 1
 
Evaluation for preliminary task
Evaluation for preliminary taskEvaluation for preliminary task
Evaluation for preliminary task
 
yOS tour de Montréal
yOS tour de MontréalyOS tour de Montréal
yOS tour de Montréal
 
ITFT - Famous wild life sancturies
ITFT - Famous wild life sancturiesITFT - Famous wild life sancturies
ITFT - Famous wild life sancturies
 
Iberian mountain
Iberian mountainIberian mountain
Iberian mountain
 

Similar to MongoDB

Mongo db basics
Mongo db basicsMongo db basics
Mongo db basics
Claudio Montoya
 
Copy of MongoDB .pptx
Copy of MongoDB .pptxCopy of MongoDB .pptx
Copy of MongoDB .pptx
nehabsairam
 
Document databases
Document databasesDocument databases
Document databases
Qframe
 
Mongo db
Mongo dbMongo db
Mongo db
Gyanendra Yadav
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
S.Shayan Daneshvar
 
Introduction to MongoDB and its best practices
Introduction to MongoDB and its best practicesIntroduction to MongoDB and its best practices
Introduction to MongoDB and its best practices
AshishRathore72
 
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB
 
Managing Social Content with MongoDB
Managing Social Content with MongoDBManaging Social Content with MongoDB
Managing Social Content with MongoDB
MongoDB
 
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and SparkVital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital.AI
 
lecture_34e.pptx
lecture_34e.pptxlecture_34e.pptx
lecture_34e.pptx
janibashashaik25
 
Mongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in BangaloreMongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in Bangalore
rajkamaltibacademy
 
3.Implementation with NOSQL databases Document Databases (Mongodb).pptx
3.Implementation with NOSQL databases Document Databases (Mongodb).pptx3.Implementation with NOSQL databases Document Databases (Mongodb).pptx
3.Implementation with NOSQL databases Document Databases (Mongodb).pptx
RushikeshChikane2
 
Introduction to MongoDB Basics from SQL to NoSQL
Introduction to MongoDB Basics from SQL to NoSQLIntroduction to MongoDB Basics from SQL to NoSQL
Introduction to MongoDB Basics from SQL to NoSQL
Mayur Patil
 
Techorama - Evolvable Application Development with MongoDB
Techorama  - Evolvable Application Development with MongoDBTechorama  - Evolvable Application Development with MongoDB
Techorama - Evolvable Application Development with MongoDB
bwullems
 
Saran 01.06.2015
Saran 01.06.2015Saran 01.06.2015
Saran 01.06.2015
Saran Raj
 
A Study on Mongodb Database.pdf
A Study on Mongodb Database.pdfA Study on Mongodb Database.pdf
A Study on Mongodb Database.pdf
Jessica Navarro
 
Spring data presentation
Spring data presentationSpring data presentation
Spring data presentation
Oleksii Usyk
 
Building your first app with MongoDB
Building your first app with MongoDBBuilding your first app with MongoDB
Building your first app with MongoDB
Norberto Leite
 
Asp.net Programming Training (Web design, Web development)
Asp.net Programming Training (Web design, Web  development)Asp.net Programming Training (Web design, Web  development)
Asp.net Programming Training (Web design, Web development)
Moutasm Tamimi
 
NOSQL and MongoDB Database
NOSQL and MongoDB DatabaseNOSQL and MongoDB Database
NOSQL and MongoDB Database
Tariqul islam
 

Similar to MongoDB (20)

Mongo db basics
Mongo db basicsMongo db basics
Mongo db basics
 
Copy of MongoDB .pptx
Copy of MongoDB .pptxCopy of MongoDB .pptx
Copy of MongoDB .pptx
 
Document databases
Document databasesDocument databases
Document databases
 
Mongo db
Mongo dbMongo db
Mongo db
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
 
Introduction to MongoDB and its best practices
Introduction to MongoDB and its best practicesIntroduction to MongoDB and its best practices
Introduction to MongoDB and its best practices
 
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
 
Managing Social Content with MongoDB
Managing Social Content with MongoDBManaging Social Content with MongoDB
Managing Social Content with MongoDB
 
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and SparkVital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
 
lecture_34e.pptx
lecture_34e.pptxlecture_34e.pptx
lecture_34e.pptx
 
Mongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in BangaloreMongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in Bangalore
 
3.Implementation with NOSQL databases Document Databases (Mongodb).pptx
3.Implementation with NOSQL databases Document Databases (Mongodb).pptx3.Implementation with NOSQL databases Document Databases (Mongodb).pptx
3.Implementation with NOSQL databases Document Databases (Mongodb).pptx
 
Introduction to MongoDB Basics from SQL to NoSQL
Introduction to MongoDB Basics from SQL to NoSQLIntroduction to MongoDB Basics from SQL to NoSQL
Introduction to MongoDB Basics from SQL to NoSQL
 
Techorama - Evolvable Application Development with MongoDB
Techorama  - Evolvable Application Development with MongoDBTechorama  - Evolvable Application Development with MongoDB
Techorama - Evolvable Application Development with MongoDB
 
Saran 01.06.2015
Saran 01.06.2015Saran 01.06.2015
Saran 01.06.2015
 
A Study on Mongodb Database.pdf
A Study on Mongodb Database.pdfA Study on Mongodb Database.pdf
A Study on Mongodb Database.pdf
 
Spring data presentation
Spring data presentationSpring data presentation
Spring data presentation
 
Building your first app with MongoDB
Building your first app with MongoDBBuilding your first app with MongoDB
Building your first app with MongoDB
 
Asp.net Programming Training (Web design, Web development)
Asp.net Programming Training (Web design, Web  development)Asp.net Programming Training (Web design, Web  development)
Asp.net Programming Training (Web design, Web development)
 
NOSQL and MongoDB Database
NOSQL and MongoDB DatabaseNOSQL and MongoDB Database
NOSQL and MongoDB Database
 

Recently uploaded

Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Safe Software
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
Neo4j
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Speck&Tech
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
Building Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and MilvusBuilding Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and Milvus
Zilliz
 
UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
DianaGray10
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
名前 です男
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
Tomaz Bratanic
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
Matthew Sinclair
 
How to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For FlutterHow to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For Flutter
Daiki Mogmet Ito
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
Mind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AIMind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AI
Kumud Singh
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
Mariano Tinti
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
Neo4j
 
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
SOFTTECHHUB
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
panagenda
 
GenAI Pilot Implementation in the organizations
GenAI Pilot Implementation in the organizationsGenAI Pilot Implementation in the organizations
GenAI Pilot Implementation in the organizations
kumardaparthi1024
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
DianaGray10
 

Recently uploaded (20)

Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
Building Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and MilvusBuilding Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and Milvus
 
UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
 
How to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For FlutterHow to use Firebase Data Connect For Flutter
How to use Firebase Data Connect For Flutter
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
Mind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AIMind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AI
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
 
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
 
GenAI Pilot Implementation in the organizations
GenAI Pilot Implementation in the organizationsGenAI Pilot Implementation in the organizations
GenAI Pilot Implementation in the organizations
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
 

MongoDB

  • 1. Web Data Management, Search and Retrieval Course (MCOM7348) University of Birzeit, Palestine January, 2014 Synthesis Paper Talk Nosql Database Fayez shayeb bbbbb Master of Computing, Birzeit University Fayez.aauj@hotmail.com Master of Computing, Birzeit University bbbbbbb@yahoo.com This is a student talk, at the Web Data Management, Search and Retrieval Course, each student is is asked to present his/her synthesis paper. Course Page: http://jarrar-courses.blogspot.com/2013/11/web-data-management.html 1
  • 2. Document-oriented database • document-oriented database is a computer program designed for storing, retrieving, and managing document-oriented, or semi structured data, information
  • 3. Comparison  Document db  Relational Article - id - authorid - title - content Author - id - name - email Comment - id - articleid - message Article - _id - title - content - author - _id - name - email - comments[]
  • 4. Concepts  Joins  No joins  Joins at "design time", not at "query time“  Due to embedded docs and arrays less joins are needed  Constraints  No foreign key constraints  Unique indexes  Transactions  No commit/rollback  Atomic operations  Multiple actions inside the same document  Incl. embedded documents
  • 5. Benefits  Scalable: good for a lot of data / traffic  Horizontal scaling: to more nodes  Good for web-apps  Performance  No joins and constraints  Dev/user friendly  Data is modeled to how the app is going to use it  No conversion between object oriented > relational  No static schema = agile
  • 6. One-to-many  Embedded array / array keys  Some queries get harder  You can index arrays!  Normalized approach  More flexibility  A lot less performance Article - _id - content - tags: {“foo”, “bar”} - comments: {“id1”, “id2”}
  • 7. many-to-many  Using array keys  No join table  References on both sides Article - _id - content - category_ids : {“id1”, “id2”} Category - _id - name - article_ids: {“id7”, “id8”}  Advantage: simple queries articles.Where(p => p.CategoryIds.Contains(categoryId)) categories.Where(c => c.ArticleIds.Contains(articleId))  Disadvantage: duplication, update two docs
  • 8. json • • • Stands for Javascript Object Notation Derived from Javascript scripting language Used for representing simple data structures and associative arrays { { "_id": "BCCD12CBB", "type": "person", "name": "Darth Vader", "age": 63, "headware": ["Helmet", "Sombrero"], "dark_side": true } "_id": "BCCD12CBC", "type": "person", "name": "Luke", "age": 35, "powers": ["Pull", "Jedi Mind Trick"], "dark_side": false }
  • 9. Replication  Only one server is active for writes (the primary, or master) at a given time – this is to allow strong consistent (atomic) operations. One can optionally send read operations to the secondaries when eventual consistency semantics are acceptable.
  • 10. Sharding  Sharding is the partitioning of data among multiple machines in an order-preserving manner.(horizontal scaling ) Machine 1 Machine 2 Machine 3 Alabama → Arizona Colorado → Florida Arkansas → California Indiana → Kansas Idaho → Illinois Georgia → Hawaii Maryland → Michigan Kentucky → Maine Minnesota → Missouri Montana → Montana Nebraska → New Jersey Ohio → Pennsylvania New Mexico → North Dakota Rhode Island → South Dakota Tennessee → Utah Vermont → West Virgina Wisconsin → Wyoming
  • 11. Sharding  The set of servers/mongod process within the shard comprise a replica set
  • 12. Replication & Sharding conclusion  sharding is the tool for scaling a system, and replication is the tool for data safety, high availability, and disaster recovery. The two work in tandem yet are orthogonal concepts in the design.
  • 14. What is MongoDB?  Creator: 10 gen, former doublick  Name: short for humongous (  Language: C++ )
  • 15. What is MongoDB?  Defination: MongoDB is an open source, document- oriented database designed with both scalability and developer agility in mind. Instead of storing your data in tables and rows as you would with a relational database, in MongoDB you store JSON-like documents with dynamic schemas(schemafree, schemaless).
  • 16. What is MongoDB?  Goal: bridge the gap between key-value stores (which are fast and scalable) and relational databases (which have rich functionality).
  • 19. MongoDB Data model  Data model: Using BSON (binary JSON), developers can easily map to modern object-oriented languages without a complicated ORM layer.  BSON is a binary format in which zero or more key/value pairs are stored as a single entity.  lightweight, traversable, efficient
  • 23. Query MongoDB Vs sql? SQL mongodb Create table db.CreateCollection() Insert into db.coll.save() select db.coll.find() update db.coll.update delete db.coll.remove() drop db.coll.drop()
  • 26. API for MongoDB : C C++ C# Erlang Haskell Java node.js PHP Perl Python Ruby Scala (Casbah)