{"id":12184,"date":"2019-11-15T12:55:52","date_gmt":"2019-11-15T12:55:52","guid":{"rendered":"https:\/\/ittutorial.org\/?p=12184"},"modified":"2019-11-16T22:51:10","modified_gmt":"2019-11-16T22:51:10","slug":"about-mongodb-why-we-use-it-mongodbs-terminology-and-implementation","status":"publish","type":"post","link":"https:\/\/ittutorial.org\/about-mongodb-why-we-use-it-mongodbs-terminology-and-implementation\/","title":{"rendered":"About MongoDB, Why we use it? MongoDB&#8217;s Terminology and Implementation"},"content":{"rendered":"<h2><\/h2>\n<p>Organizations face every day new challenges in order to continuously deliver new business functionality by implementing new It processes like Agile and DevOps and adopting new architectures such as cloud and microservices. To align with all these, we need a new database concept able to manage massive increases in rapidly changing data types and able to work with data wherever it stores in the client side and in the data layer side.<\/p>\n<p>So the NoSQL databases &#8220;Not only SQL&#8221; are designed to respond to these challenges. MongoDB is the leading NoSQL database and an open-source document database.<\/p>\n<p>In this article we will explain MongoDB concepts, give an idea on its advantages and terminology and where we can implement it.<\/p>\n<h4><strong>MongoDB\u2019s Advantages: <\/strong><\/h4>\n<p>MongoDB\u2019s data platform is based on two principles concepts:<\/p>\n<ul>\n<li><strong>Document database<\/strong>: MongoDB uses the document as data model which is similar to JSON objects. It is a data structure composed of field and value pairs. The values may include sub-documents, arrays, and arrays of documents; which reduce the need for expensive joins.\u00a0 Using this data model it\u2019s will be faster and easier to model how application objects will map to data since\u00a0 it corresponds to native data types . Beyond the ease-of-use, documents are flexible since we can modify our schema at any time, it is polymorphic because documents can have different structures compared to other documents in the same collection\u00a0 and it is extensible :we model data in any way application demands it.<\/li>\n<li style=\"text-align: left\"><strong> Distributed Data:<\/strong> MongoDB offers the ability to scale out the system and distribute data for low latency user access. Implementing \u201cSharding\u201d and \u201cReplica sets\u201d techniques make it easy to distribute data and grow our deployment over inexpensive hardware.<\/li>\n<\/ul>\n<h4>Basics Terminology:<\/h4>\n<p>MongoDB stores\u00a0 <a href=\"https:\/\/docs.mongodb.com\/manual\/core\/document\/&quot; \\l &quot;bson-document-format\">BSON documents<\/a> in\u00a0<a href=\"https:\/\/docs.mongodb.com\/manual\/reference\/glossary\/#term-collection\">collections<\/a>; the collections in database. A single MongoDB server typically has multiple databases. Each database gets its own set of files on the file system as format of collections. Each collection is a set of documents . One of the collection&#8217;s major advantage is no enforcing of schemas and in the same time we have a dynamic schema. Dynamic schema means that documents in the same collection do not need to have the same set of fields or structure, and common fields in a collection&#8217;s documents may hold different types of data.<\/p>\n<p>The following figure shows the correspondence terminology of Relational Database with MongoDB:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-12187 aligncenter\" src=\"https:\/\/ittutorial.org\/wp-content\/uploads\/2019\/11\/word-image.png\" width=\"517\" height=\"165\" srcset=\"https:\/\/ittutorial.org\/wp-content\/uploads\/2019\/11\/word-image.png 451w, https:\/\/ittutorial.org\/wp-content\/uploads\/2019\/11\/word-image-300x96.png 300w\" sizes=\"auto, (max-width: 517px) 100vw, 517px\" \/><\/p>\n<h4>Query Language:<\/h4>\n<p>Both RDBMS (Oracle and MySQL) and MongoDB have a rich query language.<\/p>\n<p>The following figure shows the Query Language&#8217;s correspondence Of RDBMS and MongoDb:<\/p>\n<p><strong> <img loading=\"lazy\" decoding=\"async\" class=\"wp-image-12188 aligncenter\" src=\"https:\/\/ittutorial.org\/wp-content\/uploads\/2019\/11\/word-image-1.png\" width=\"601\" height=\"222\" srcset=\"https:\/\/ittutorial.org\/wp-content\/uploads\/2019\/11\/word-image-1.png 482w, https:\/\/ittutorial.org\/wp-content\/uploads\/2019\/11\/word-image-1-300x111.png 300w\" sizes=\"auto, (max-width: 601px) 100vw, 601px\" \/><\/strong><\/p>\n<h4>Implementation:<\/h4>\n<p>To take advantage from MongoDB, we can choose implement MongoDB in these fields:<\/p>\n<ul>\n<li>E-commerce product catalog<\/li>\n<li>Blogs , content management and Delivery<\/li>\n<li>Mobile and Social Infrastructure<\/li>\n<li>Big Data<\/li>\n<li>User Data Management<\/li>\n<li>Data Hub<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Organizations face every day new challenges in order to continuously deliver new business functionality by implementing new It processes like Agile and DevOps and adopting new architectures such as cloud and microservices. To align with all these, we need a new database concept able to manage massive increases in rapidly changing data types and able &hellip;<\/p>\n","protected":false},"author":10452,"featured_media":12190,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_uf_show_specific_survey":0,"_uf_disable_surveys":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[6797,6798],"tags":[6803,6802,6805,6804,6806,6807,6810,6800,6809,6808,6799,6801],"class_list":["post-12184","post","type-post","status-publish","format-standard","has-post-thumbnail","","category-mongodb","category-nosql","tag-bson-document","tag-collections","tag-distributed-data","tag-document-database","tag-embedded-documents","tag-mangodbs-query-language","tag-mogodb-tutoriel","tag-mongodb","tag-mongodbs-concepts","tag-mongodbsterminology","tag-nosql-database","tag-why-we-use-mongodb"],"aioseo_notices":[],"jetpack_featured_media_url":"https:\/\/ittutorial.org\/wp-content\/uploads\/2019\/11\/MongoDB.png","jetpack_sharing_enabled":true,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/posts\/12184","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/users\/10452"}],"replies":[{"embeddable":true,"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/comments?post=12184"}],"version-history":[{"count":5,"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/posts\/12184\/revisions"}],"predecessor-version":[{"id":12243,"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/posts\/12184\/revisions\/12243"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/media\/12190"}],"wp:attachment":[{"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/media?parent=12184"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/categories?post=12184"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ittutorial.org\/wp-json\/wp\/v2\/tags?post=12184"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}