SlideShare une entreprise Scribd logo
1  sur  20
Télécharger pour lire hors ligne
An Introduction
Deepak Kumar | @_deepak0
An Introduction
Deepak Kumar | @_deepak0
MongoDB
● Document oriented
  a. Objects are mapped as documents
  b. Documents can be embedded
  c. Dynamically typed
● No Schema
● High availability
  a. Replication through sharding.
  b. Automatic failover
● Easy scaling
  a. Auto shrading ( auto partitioning data across servers)
● Speed
Programming Language Support
Supported by all the popular programming
languages (C++, Java, Python, Ruby, Go, Haskel
etc...) and web frameworks ( Rails, Django etc).
Interesting Fact




There are MongoDB systems that exceed one
       million operations per second.
MongoDB document model
Key         Key                Value




                    Field




                  Document



                  Collection




                   Database
Data Types Supported
●   String
●   Number
●   Boolean
●   Date
●   Null
●   Array
●   Object ID
●   Binary data
●   Regular Expression
Why should we use Mongodb
●   Easy to scale
●   Coding velocity (agility)
●   No impedance mismatch
●   Allows dynamic schema ( No Schema, agility)
●   Easier to store and manipulate polymorphic data
●   Variety of Indexing
●   A MapReduce tool.
Impedance Mismatch
In object relational mapping an object in
programming language is mapped to a record in
database. So if the data is simple and database
support it then there is no mismatch.

But if the data is polymorphic and have unsupported
types then the mapping will be difficult which
causes a impedance mismatch.

In mongodb data is of JSON format so it can map
well to the object.
Where should we avoid MongoDB
● Problems with SQL support.
● Systems with heavy emphasis on complex
  transactions such as banking.
● Data Warehousing whose underlying database
  are schema based.
Indexing
● Indexing can be done on a field
● Indexing can be done on an embedded object.
● Sparse indexing - Indexing based existence of
  field.
● TTL index
● Geospatial Index ( Location based access)
● Geohaystack index (Bucket based small regions)
MongoDB/ Components
● Mongod => Database Process
● Mongoes => Shrading Controller
● Mongo => Database Shell ( javascript shell)
MongoDB/Utilities
● mongodump => Dump tool for backup and
  snapshot
● mongorestore => Restore a dump
● mongoexport => Export a single collection to
  JSON or CSV
● mongoimport => Import from JSON or CSV
● mongofiles => Utility for putting and getting
  files from MongoDB GridFS
● mongostat => Performance statistics tool
Single Server Configuration
● Install mongodb
● create a database directory
  eg: mkdir -p /data/db
● create a configuration file (optional)
  eg: /etc/mongodb.conf
● start the mongodb server
  sudo mongod -f /etc/mongodb.conf OR use init
  script.
● connect to the database using javascript console
  mongo
  You will get connected to test database.
MongoDB Multiserver Configuration
Third party Software Used With
                MogoDB
Boost => Portable open source C++ libraries.
V8     => Javascript runtime.
PCRE => Perl compatible regular expression.
MD5 => Message Digest Algorithm
Snappy => fast compression and decompression tool
Edda - Admin Tool

● Edda provides a graphical visualization of
  mongodb servers .

● Edda provides an easy way to check the status in
  multiserver configuration.
Companies Using MongoDB
●   Foursquare
●   MTV networks
●   Disney
●   Customlnk
●   Sourceforge
●   Wowmakers
●   and many others ....
Thanks
Questions ?

Contenu connexe

Tendances

Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDBMike Dirolf
 
Mongo db present
Mongo db presentMongo db present
Mongo db presentscottmsims
 
MongoDB presentation
MongoDB presentationMongoDB presentation
MongoDB presentationHyphen Call
 
Austin bdug 2011_01_27_small_and_big_data
Austin bdug 2011_01_27_small_and_big_dataAustin bdug 2011_01_27_small_and_big_data
Austin bdug 2011_01_27_small_and_big_dataAlex Pinkin
 
SOLR Power FTW: short version
SOLR Power FTW: short versionSOLR Power FTW: short version
SOLR Power FTW: short versionAlex Pinkin
 
MongoDB for the SQL Server
MongoDB for the SQL ServerMongoDB for the SQL Server
MongoDB for the SQL ServerPaulo Fagundes
 
Hadoop con2016 - Implement Real-time Centralized logging System by Elastic Stack
Hadoop con2016 - Implement Real-time Centralized logging System by Elastic StackHadoop con2016 - Implement Real-time Centralized logging System by Elastic Stack
Hadoop con2016 - Implement Real-time Centralized logging System by Elastic StackLen Chang
 
Intro To Graph Databases - Oxana Goriuc
Intro To Graph Databases - Oxana GoriucIntro To Graph Databases - Oxana Goriuc
Intro To Graph Databases - Oxana GoriucFraugster
 
Building a Directed Graph with MongoDB
Building a Directed Graph with MongoDBBuilding a Directed Graph with MongoDB
Building a Directed Graph with MongoDBTony Tam
 
Top 10 frameworks of node js
Top 10 frameworks of node jsTop 10 frameworks of node js
Top 10 frameworks of node jsHabilelabs
 
Mateusz Gruszczynski - Performance tests in Gatling (Quality Questions Confer...
Mateusz Gruszczynski - Performance tests in Gatling (Quality Questions Confer...Mateusz Gruszczynski - Performance tests in Gatling (Quality Questions Confer...
Mateusz Gruszczynski - Performance tests in Gatling (Quality Questions Confer...Grand Parade Poland
 
Comparison with storing data using NoSQL(CouchDB) and a relational database.
Comparison with storing data using NoSQL(CouchDB) and a relational database.Comparison with storing data using NoSQL(CouchDB) and a relational database.
Comparison with storing data using NoSQL(CouchDB) and a relational database.eross77
 

Tendances (20)

Performance (browser)
Performance (browser)Performance (browser)
Performance (browser)
 
Mongo db
Mongo dbMongo db
Mongo db
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
 
Open source Technology
Open source TechnologyOpen source Technology
Open source Technology
 
Mongo db present
Mongo db presentMongo db present
Mongo db present
 
MongoDB presentation
MongoDB presentationMongoDB presentation
MongoDB presentation
 
Austin bdug 2011_01_27_small_and_big_data
Austin bdug 2011_01_27_small_and_big_dataAustin bdug 2011_01_27_small_and_big_data
Austin bdug 2011_01_27_small_and_big_data
 
New paradigms
New paradigmsNew paradigms
New paradigms
 
Mongo db workshop # 02
Mongo db workshop # 02Mongo db workshop # 02
Mongo db workshop # 02
 
SOLR Power FTW: short version
SOLR Power FTW: short versionSOLR Power FTW: short version
SOLR Power FTW: short version
 
MongoDB for the SQL Server
MongoDB for the SQL ServerMongoDB for the SQL Server
MongoDB for the SQL Server
 
Hadoop con2016 - Implement Real-time Centralized logging System by Elastic Stack
Hadoop con2016 - Implement Real-time Centralized logging System by Elastic StackHadoop con2016 - Implement Real-time Centralized logging System by Elastic Stack
Hadoop con2016 - Implement Real-time Centralized logging System by Elastic Stack
 
Intro To Graph Databases - Oxana Goriuc
Intro To Graph Databases - Oxana GoriucIntro To Graph Databases - Oxana Goriuc
Intro To Graph Databases - Oxana Goriuc
 
Building a Directed Graph with MongoDB
Building a Directed Graph with MongoDBBuilding a Directed Graph with MongoDB
Building a Directed Graph with MongoDB
 
Top 10 frameworks of node js
Top 10 frameworks of node jsTop 10 frameworks of node js
Top 10 frameworks of node js
 
Mongo db onepage
Mongo db onepageMongo db onepage
Mongo db onepage
 
Mateusz Gruszczynski - Performance tests in Gatling (Quality Questions Confer...
Mateusz Gruszczynski - Performance tests in Gatling (Quality Questions Confer...Mateusz Gruszczynski - Performance tests in Gatling (Quality Questions Confer...
Mateusz Gruszczynski - Performance tests in Gatling (Quality Questions Confer...
 
Comparison with storing data using NoSQL(CouchDB) and a relational database.
Comparison with storing data using NoSQL(CouchDB) and a relational database.Comparison with storing data using NoSQL(CouchDB) and a relational database.
Comparison with storing data using NoSQL(CouchDB) and a relational database.
 
18.xml
18.xml18.xml
18.xml
 
Starting with MongoDB
Starting with MongoDBStarting with MongoDB
Starting with MongoDB
 

Similaire à Mongodb (1)

Mongo db transcript
Mongo db transcriptMongo db transcript
Mongo db transcriptfoliba
 
MongoDB: Advantages of an Open Source NoSQL Database
MongoDB: Advantages of an Open Source NoSQL DatabaseMongoDB: Advantages of an Open Source NoSQL Database
MongoDB: Advantages of an Open Source NoSQL DatabaseFITC
 
Node Js, AngularJs and Express Js Tutorial
Node Js, AngularJs and Express Js TutorialNode Js, AngularJs and Express Js Tutorial
Node Js, AngularJs and Express Js TutorialPHP Support
 
What is the significance of MongoDB and what are its usages.docx
What is the significance of MongoDB and what are its usages.docxWhat is the significance of MongoDB and what are its usages.docx
What is the significance of MongoDB and what are its usages.docxkzayra69
 
Introduction to mongo db by zain
Introduction to mongo db by zainIntroduction to mongo db by zain
Introduction to mongo db by zainKenAndTea
 
AWS big-data-demystified #1.1 | Big Data Architecture Lessons Learned | English
AWS big-data-demystified #1.1  | Big Data Architecture Lessons Learned | EnglishAWS big-data-demystified #1.1  | Big Data Architecture Lessons Learned | English
AWS big-data-demystified #1.1 | Big Data Architecture Lessons Learned | EnglishOmid Vahdaty
 
What are the major components of MongoDB and the major tools used in it.docx
What are the major components of MongoDB and the major tools used in it.docxWhat are the major components of MongoDB and the major tools used in it.docx
What are the major components of MongoDB and the major tools used in it.docxTechnogeeks
 
Top MongoDB interview Questions and Answers
Top MongoDB interview Questions and AnswersTop MongoDB interview Questions and Answers
Top MongoDB interview Questions and Answersjeetendra mandal
 
MongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer GuideMongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer GuideShiv K Sah
 
Mongo db first steps with csharp
Mongo db first steps with csharpMongo db first steps with csharp
Mongo db first steps with csharpSerdar Buyuktemiz
 
AWS Big Data Demystified #1: Big data architecture lessons learned
AWS Big Data Demystified #1: Big data architecture lessons learned AWS Big Data Demystified #1: Big data architecture lessons learned
AWS Big Data Demystified #1: Big data architecture lessons learned Omid Vahdaty
 
Big Data in 200 km/h | AWS Big Data Demystified #1.3
Big Data in 200 km/h | AWS Big Data Demystified #1.3  Big Data in 200 km/h | AWS Big Data Demystified #1.3
Big Data in 200 km/h | AWS Big Data Demystified #1.3 Omid Vahdaty
 
kranonit S06E01 Игорь Цинько: High load
kranonit S06E01 Игорь Цинько: High loadkranonit S06E01 Игорь Цинько: High load
kranonit S06E01 Игорь Цинько: High loadKrivoy Rog IT Community
 
MongoDB Introduction - Document Oriented Nosql Database
MongoDB Introduction - Document Oriented Nosql DatabaseMongoDB Introduction - Document Oriented Nosql Database
MongoDB Introduction - Document Oriented Nosql DatabaseSudhir Patil
 
Building RESTtful services in MEAN
Building RESTtful services in MEANBuilding RESTtful services in MEAN
Building RESTtful services in MEANMadhukara Phatak
 

Similaire à Mongodb (1) (20)

Mongo db transcript
Mongo db transcriptMongo db transcript
Mongo db transcript
 
MongoDB: Advantages of an Open Source NoSQL Database
MongoDB: Advantages of an Open Source NoSQL DatabaseMongoDB: Advantages of an Open Source NoSQL Database
MongoDB: Advantages of an Open Source NoSQL Database
 
Node Js, AngularJs and Express Js Tutorial
Node Js, AngularJs and Express Js TutorialNode Js, AngularJs and Express Js Tutorial
Node Js, AngularJs and Express Js Tutorial
 
What is the significance of MongoDB and what are its usages.docx
What is the significance of MongoDB and what are its usages.docxWhat is the significance of MongoDB and what are its usages.docx
What is the significance of MongoDB and what are its usages.docx
 
Mongodb
MongodbMongodb
Mongodb
 
Introduction to mongo db by zain
Introduction to mongo db by zainIntroduction to mongo db by zain
Introduction to mongo db by zain
 
MongoDB
MongoDBMongoDB
MongoDB
 
MongoDB Basics Unileon
MongoDB Basics UnileonMongoDB Basics Unileon
MongoDB Basics Unileon
 
AWS big-data-demystified #1.1 | Big Data Architecture Lessons Learned | English
AWS big-data-demystified #1.1  | Big Data Architecture Lessons Learned | EnglishAWS big-data-demystified #1.1  | Big Data Architecture Lessons Learned | English
AWS big-data-demystified #1.1 | Big Data Architecture Lessons Learned | English
 
What are the major components of MongoDB and the major tools used in it.docx
What are the major components of MongoDB and the major tools used in it.docxWhat are the major components of MongoDB and the major tools used in it.docx
What are the major components of MongoDB and the major tools used in it.docx
 
Mongodb
MongodbMongodb
Mongodb
 
Mongo db basics
Mongo db basicsMongo db basics
Mongo db basics
 
Top MongoDB interview Questions and Answers
Top MongoDB interview Questions and AnswersTop MongoDB interview Questions and Answers
Top MongoDB interview Questions and Answers
 
MongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer GuideMongoDB NoSQL - Developer Guide
MongoDB NoSQL - Developer Guide
 
Mongo db first steps with csharp
Mongo db first steps with csharpMongo db first steps with csharp
Mongo db first steps with csharp
 
AWS Big Data Demystified #1: Big data architecture lessons learned
AWS Big Data Demystified #1: Big data architecture lessons learned AWS Big Data Demystified #1: Big data architecture lessons learned
AWS Big Data Demystified #1: Big data architecture lessons learned
 
Big Data in 200 km/h | AWS Big Data Demystified #1.3
Big Data in 200 km/h | AWS Big Data Demystified #1.3  Big Data in 200 km/h | AWS Big Data Demystified #1.3
Big Data in 200 km/h | AWS Big Data Demystified #1.3
 
kranonit S06E01 Игорь Цинько: High load
kranonit S06E01 Игорь Цинько: High loadkranonit S06E01 Игорь Цинько: High load
kranonit S06E01 Игорь Цинько: High load
 
MongoDB Introduction - Document Oriented Nosql Database
MongoDB Introduction - Document Oriented Nosql DatabaseMongoDB Introduction - Document Oriented Nosql Database
MongoDB Introduction - Document Oriented Nosql Database
 
Building RESTtful services in MEAN
Building RESTtful services in MEANBuilding RESTtful services in MEAN
Building RESTtful services in MEAN
 

Mongodb (1)

  • 3. MongoDB ● Document oriented a. Objects are mapped as documents b. Documents can be embedded c. Dynamically typed ● No Schema ● High availability a. Replication through sharding. b. Automatic failover ● Easy scaling a. Auto shrading ( auto partitioning data across servers) ● Speed
  • 4. Programming Language Support Supported by all the popular programming languages (C++, Java, Python, Ruby, Go, Haskel etc...) and web frameworks ( Rails, Django etc).
  • 5. Interesting Fact There are MongoDB systems that exceed one million operations per second.
  • 6. MongoDB document model Key Key Value Field Document Collection Database
  • 7. Data Types Supported ● String ● Number ● Boolean ● Date ● Null ● Array ● Object ID ● Binary data ● Regular Expression
  • 8. Why should we use Mongodb ● Easy to scale ● Coding velocity (agility) ● No impedance mismatch ● Allows dynamic schema ( No Schema, agility) ● Easier to store and manipulate polymorphic data ● Variety of Indexing ● A MapReduce tool.
  • 9. Impedance Mismatch In object relational mapping an object in programming language is mapped to a record in database. So if the data is simple and database support it then there is no mismatch. But if the data is polymorphic and have unsupported types then the mapping will be difficult which causes a impedance mismatch. In mongodb data is of JSON format so it can map well to the object.
  • 10. Where should we avoid MongoDB ● Problems with SQL support. ● Systems with heavy emphasis on complex transactions such as banking. ● Data Warehousing whose underlying database are schema based.
  • 11. Indexing ● Indexing can be done on a field ● Indexing can be done on an embedded object. ● Sparse indexing - Indexing based existence of field. ● TTL index ● Geospatial Index ( Location based access) ● Geohaystack index (Bucket based small regions)
  • 12. MongoDB/ Components ● Mongod => Database Process ● Mongoes => Shrading Controller ● Mongo => Database Shell ( javascript shell)
  • 13. MongoDB/Utilities ● mongodump => Dump tool for backup and snapshot ● mongorestore => Restore a dump ● mongoexport => Export a single collection to JSON or CSV ● mongoimport => Import from JSON or CSV ● mongofiles => Utility for putting and getting files from MongoDB GridFS ● mongostat => Performance statistics tool
  • 14. Single Server Configuration ● Install mongodb ● create a database directory eg: mkdir -p /data/db ● create a configuration file (optional) eg: /etc/mongodb.conf ● start the mongodb server sudo mongod -f /etc/mongodb.conf OR use init script. ● connect to the database using javascript console mongo You will get connected to test database.
  • 16. Third party Software Used With MogoDB Boost => Portable open source C++ libraries. V8 => Javascript runtime. PCRE => Perl compatible regular expression. MD5 => Message Digest Algorithm Snappy => fast compression and decompression tool
  • 17. Edda - Admin Tool ● Edda provides a graphical visualization of mongodb servers . ● Edda provides an easy way to check the status in multiserver configuration.
  • 18. Companies Using MongoDB ● Foursquare ● MTV networks ● Disney ● Customlnk ● Sourceforge ● Wowmakers ● and many others ....