✍INDUSTRY USE-CASES OF MongoDB :

Priya Soni
8 min readMay 10, 2021

✍WHAT IS MongoDB ?

MongoDB is a document-oriented NoSQL database used for high volume data storage. Instead of using tables and rows as in the traditional relational databases, MongoDB makes use of collections and documents.

Documents consist of key-value pairs which are the basic unit of data in MongoDB. Collections contain sets of documents and function which is the equivalent of relational database tables.

MongoDB stores data in flexible, JSON-like documents, meaning fields can vary from document to document and data structure can be changed over time.

MongoDB is a distributed database at its core, so high availability, horizontal scaling, and geographic distribution are built in and easy to use.

✍WHY WE USE MongoDB ?

Below are the few of the reasons as to why one should start using MongoDB :

  1. Document Oriented Storage − Data is stored in the form of JSON style documents.

2. Index on any attribute

3. Replication and high availability

4. Auto-Sharding

5. Rich queries

6. Fast in-place updates

7. Professional support by MongoDB

✍WHERE TO USE Mongo DB ?

  1. Big Data

2. Content Management and Delivery

3. Mobile and Social Infrastructure

4. User Data Management

5. Data Hub

✍ADVANTAGES AND LIMITATIONS OF Mongo DB :

✍DATABASE :

Database is a physical container for collections. Each database gets its own set of files on the file system. A single MongoDB server typically has multiple databases.

✍COLLECTION :

Collection is a group of MongoDB documents. It is the equivalent of an RDBMS table. A collection exists within a single database. Collections do not enforce a schema. Documents within a collection can have different fields. Typically, all documents in a collection are of similar or related purpose.

✍DOCUMENT :

A document is a set of key-value pairs. Documents have 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’s documents may hold different types of data.

✍FEATURES OF MongoDB :

  1. Each database contains collections which in turn contains documents. Each document can be different with a varying number of fields. The size and content of each document can be different from each other.
  2. The document structure is more in line with how developers construct their classes and objects in their respective programming languages. Developers will often say that their classes are not rows and columns but have a clear structure with key-value pairs.
  3. The rows (or documents as called in MongoDB) doesn’t need to have a schema defined beforehand. Instead, the fields can be created on the fly.
  4. The data model available within MongoDB allows you to represent hierarchical relationships, to store arrays, and other more complex structures more easily.
  5. Scalability — The MongoDB environments are very scalable. Companies across the world have defined clusters with some of them running 100+ nodes with around millions of documents within the database.

✍DATA MODELING IN MongoDB :

As we have seen from the Introduction section, the data in MongoDB has a flexible schema. Unlike in SQL databases, where you must have a table’s schema declared before inserting data, MongoDB’s collections do not enforce document structure. This sort of flexibility is what makes MongoDB so powerful.

When modeling data in Mongo, keep the following things in mind :

  1. What are the needs of the application — Look at the business needs of the application and see what data and the type of data needed for the application. Based on this, ensure that the structure of the document is decided accordingly.
  2. What are data retrieval patterns — If you foresee a heavy query usage then consider the use of indexes in your data model to improve the efficiency of queries.
  3. Are frequent inserts, updates and removals happening in the database? Reconsider the use of indexes or incorporate sharding if required in your data modeling design to improve the efficiency of your overall MongoDB environment.

✍What is NoSQL?

NoSQL Database is a non-relational Data Management System, that does not require a fixed schema. It avoids joins, and is easy to scale. The major purpose of using a NoSQL database is for distributed data stores with humongous data storage needs.

NoSQL is used for Big data and real-time web apps. For example, companies like Twitter, Facebook and Google collect terabytes of user data every single day.

Traditional RDBMS uses SQL syntax to store and retrieve data for further insights. Instead, a NoSQL database system encompasses a wide range of database technologies that can store structured, semi-structured, unstructured and polymorphic data.

✍WHAT IS USE OF MongoDB ATLAS ?

MongoDB Atlas is the global cloud database service for modern applications. Deploy fully managed MongoDB across AWS, Google Cloud, and Azure with best-in-class automation and proven practices that guarantee availability, scalability, and compliance with the most demanding data security and privacy standards.

✍ MongoDB CASE STUDY : CISCO

👉CISCO :

Cisco is the worldwide leader in networking, transforming how people connect, communicate and collaborate. In November 2011, Cisco launched WebEx Social (previously known as Quad), an enterprise collaboration platform designed for today’s social, mobile, visual and virtual workforce. A “Facebook for enterprises,” WebEx Social connects people to the information and expertise they need, when they need it.

Users share knowledge and ideas throughout the enterprise, and across geographic and organizational boundaries. When their existing relational database needed a NoSQL extension to power the collaborative workspace, Cisco turned to MongoDB as their NoSQL database of choice.

👉THE PROBLEM :

WebEx Social is a true Enterprise 2.0 platform, “a place where people ‘live’ at work,” according to Biren Gandhi, principal architect for Cisco’s Cloud Collaboration Applications Technology Group (CCATG). The comprehensive collaboration platform combines the four core Enterprise 2.0 pillars — business processes, content, communication and social features — that enable users to work together effortlessly. With their existing relational database, complex SQL queries against highly normalized schema were time consuming and Cisco had little room to scale horizontally. Additionally, it was difficult to manage schema upgrades and migrate data from release to release.

👉Why MongoDB ?

MongoDB now serves as the primary real-time data store for WebEx Social’s social features that are write-heavy in nature. For example, a social activity feed that notifies thousands of users depending on some complex privacy and visibility rules.

Additionally, Cisco uses MongoDB to perform some social network analytics. With MongoDB’s lightweight MapReduce feature, Cisco developers are able to automatically generate, with ease, recommendations such as users to connect with, communities to join and interesting content to view, as well as statistics, including top contributors, most popular colleagues and most downloaded docs.

“MongoDB is a very active, open source project with a vibrant community. It matches WebEx Social’s feature set and fits in line exactly with our needs,” said Gandhi.

👉EASY TO IMPLEMENT DOCUMENT MODEL :

MongoDB’s document-based data model offers Cisco the right balance between complex relational databases and the pure key value store of most NoSQL solutions.

Intuitive mapping from the domain model to JSON docs and complex querying capabilities enable Cisco to cross-reference users and query embedded lists, functions that were either not possible in their existing database or were costly to perform. In contrast with a relational model, which requires a three-step process of fetch-update-commit, MongoDB’s in-place atomic updates allow for “one-stop operations,” according to Gandhi.

👉MILLISECOND RESPONSE TIME :

With MongoDB, Cisco sped up reads from 30 seconds in some extreme cases to tens of milliseconds per object and eliminated caching needs in certain cases. As the WebEx Social platform evolves, Cisco plans to migrate more write-heavy features to MongoDB.

👉HIGHLY SCALABLE :

MongoDB meets the demands of WebEx Social’s high-volume write activity. MongoDB offers a fast, easy way to de-normalize, index and extract information from data stores and its unique compound and geospatial indexing are a big plus.

👉HIGH AVAILABILITY :

Cisco uses built-in sharding and replica sets, which are easy to use and enable high availability through automatic failover of nodes and recovery of member nodes.

As part of various innovation initiatives at Cisco, many developers participate in voluntary projects where people can collaborate and share results on their ideas. Many have taken up MongoDB as part of their project development, a testament to the usability, flexibility and innovation that the database offers.

👉RESULTS :

The Cisco development team is constantly evaluating the most effective product roadmap to drive customer success on WebEx Social. MongoDB provides Cisco with a user friendly platform for customers and an easy, powerful technology for developers. Cisco is focused on rolling out new features quickly and offering flexibility to users, and “MongoDB is a big piece of that,” said Gandhi.

✍CONCLUSION :

Users share knowledge and ideas throughout the enterprise, and across geographic and organizational boundaries. When their existing relational database needed a NoSQL extension to power the collaborative workspace, Cisco turned to MongoDB as their NoSQL database of choice.

This blog provides a sound idea of how Cisco team chose MongoDB as the foundation for their new platform to get away from the monolithic RDBMS configuration. MongoDB allowed them to get zero downtime upgrades and deployments whilst simultaneously improving their application performance and developer agility.

Finally I have successfully completed this task. Thank you Vimal Daga sir for giving me such a great task. Sir your mentorship is a God gift for me to enhance my skills and I am very blessed because you are my mentor.

So guys, In the upcoming days I am going to be publish a lots of blogs and articles on different different automation tools and other technologies, So definetely follow me on Medium as well as on linkedIn.

So, Here is my linkedIn profile if you have any queries definitely comment below or DM me on linkedIn.

SEE YOU IN THE NEXT BLOG WITH MORE AMAZING TASKS.

SIGNING OF FORM MY SIDE 👋👋

KEEP LEARNING🙇‍♂️📖🙇….

KEEP SHARING✌✌….

--

--