What is MongoDB? | Industry Use Cases of MongoDB

Bhavesh S. Sonewale
5 min readSep 27, 2021

What Is MongoDB?

MongoDB is an open-source document database and leading NoSQL database. MongoDB is written in C++.

MongoDB is a cross-platform, document-oriented database that provides, high performance, high availability, and easy scalability. MongoDB works on the concept of collection and document.

MongoDB Features:

Being a NoSQL database, MongoDB has so many great features. These amazing features make this technology very unique and attractive.

1. Ad-hoc Queries

MongoDB supports ad-hoc queries by indexing.

2. Schema-Less Database

It is very flexible than structured databases. There is no need to type mapping.

3. Document Oriented

It is document-oriented, JSON like a database.

4. Indexing

Any document can index with primary and secondary indices.

5. Replication

It has this powerful tool. Every document has one primary node which further has two or more secondary replications.

6. Aggregation

For efficient usability, MongoDB has an aggregation framework for batch processing.

7. GridFS

It has a grid file system, so it can use to store files in multiple machines.

8. Sharding

For the larger data sets sharding is the best feature. It distributes larger data to multiple machines.

9. High Performance

Indexes support faster queries leading to high performance.

Need to run MongoDB?

  • High availability through built-in replication and failover
  • Scalability with native sharding
  • End-to-end security
  • Native document validation and schema exploration with Compass
  • Management tooling for automation, monitoring, and backup
  • Fully elastic database as a service with built-in best practices

Components of MongoDB Architecture:

Below are a few of the common terms used in MongoDB

  1. id: This is a field required in every MongoDB document. The _id field represents a unique value in the MongoDB document. The _id field is like the document’s primary key. If you create a new document without an _id field, MongoDB will automatically create the field. So for example, if we see the example of the above customer table, Mongo DB will add a 24 digit unique identifier to each document in the collection.

2. Collection: This is a grouping of MongoDB documents. A collection is the equivalent of a table that is created in any other RDMS such as Oracle or MS SQL. A collection exists within a single database. As seen from the introduction collections don’t enforce any sort of structure.

3. Cursor: This is a pointer to the result set of a query. Clients can iterate through a cursor to retrieve results.

4. Database: This is a container for collections like in RDMS wherein it is a container for tables. Each database gets its own set of files on the file system. A MongoDB server can store multiple databases.

5. Document: A record in a MongoDB collection is basically called a document. The document, in turn, will consist of field names and values.

6. Field: A name-value pair in a document. A document has zero or more fields. Fields are analogous to columns in relational databases.

7. JSON: This is known as JavaScript Object Notation. This is a human-readable, plain text format for expressing structured data. JSON is currently supported in many programming languages.

MongoDB Applications

  • In E-commerce product catalog.
  • Big data
  • Content management
  • Real-time analytics and high-speed logging.
  • Maintain Geolocations
  • Maintaining data from social websites.

MongoDB Case Study: Toyota

We all know the Toyota name as a manufacturer of cars but it has a broader and richer history than just that. Toyota Material handling is building both the machines and the data platforms, that will make this historic shift in manufacturing success. Toyota is famous for the quality of its vehicles. Now that same standard is being applied to how its development teams create Internet of Things software that will enable the move to smart, autonomous, and safer factories of the future.

Now Toyota Materials handlings are creating smarter factories by moving to MongoDB. With big data collected from vehicles and analyzed on a cloud platform, TCNA humanizes the driving experience by freeing customers from the tyranny of technology via secure, seamless, and contextual services, elevating the customer experience while benefiting dealers, distributors, and partners. In August 2019, it launched its homegrown Telematics Services Platform (TSP) which leverages a special piece of hardware available in select new Toyota and Lexus vehicles to enable safety and convenience services such as collision detection, roadside assistance, destination assist, and stolen vehicle support. MongoDB has reduced TCNA’s annual costs by 20% and given its developers time back so they keep up with evolving consumer expectations and continue to innovate.

Why Toyota choose MongoDB?

Toyota Material Handling had eight evaluation criteria that were used to decide on which database platform they would use to make the switch:

  1. Performance: latency, scalable reads and writes to meet customer SL As and accommodate significant growth in the future
  2. Automatic scalability, operations, and maintenance that enable developers to focus on applications, rather than backend database administration
  3. Security and compliance to safeguard highly sensitive business and personal data
  4. Data locality able to host in Northwest Europe or West Europe in Microsoft Azure, therefore, ensuring close geographic proximity to factories for latency-sensitive operations
  5. Automatic backups and restore to provide fully managed data protection and disaster recovery
  6. Cloud agnostic, giving customers the freedom to run anywhere, on any platform
  7. Developer friendly database with a flexible data model so that developers can continuously integrate new application functionality and stay ahead of market demands
  8. Ecosystem for developer productivity, using proven best practices and widely available skills.

So that’s all for today. Will come back again with another interesting article. Thanks for reading.

Connect with me on LinkedIn :-

https://www.linkedin.com/in/bhaveshsonewale/

--

--

Bhavesh S. Sonewale

2x Red Hat Certified | Aspiring DevOps Engineer | Aviatrix Certified Engineer| AWS | Ansible | Openshift | Docker | Kubernetes