MongoDB Database Introduction

MongoDB is an open-source document database and a 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 database, collection, and document.

Database, so MongoDB is a NoSQL database that stores the data in the form of key-value pairs. It is an Open Source, Document Database which provides high performance and scalability along with data modeling and data management of huge sets of data in an enterprise application.MongoDB also provides the feature of Auto-Scaling. Since, MongoDB is a cross-platform database and can be installed across different platforms like Windows, Linux, etc.

History of MongoDB

MongoDB was developed by Eliot Horowitz and Dwight Merriman in the year 2007, when they experienced some scalability issues with the relational database while developing enterprise web applications at their company DoubleClick. According to Dwight Merriman, one of the developers of MongoDB, this name of the database was derived from the word humongous to support the idea of processing a large amounts of data.

The 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.

Example of Data Storage in MongoDB :

Document-based storage: A Document is nothing but a data structure with name-value pairs like in JSON. It is very easy to map any custom Object of any programming language with a MongoDB Document.

example: Employee object has attributes name, EmpID, Designation, salary.

Document for Employee in MongoDB will be like :

{
            name : "Nitin Kumar",
            EmpID : 10001,
            Salary : XXXXX
}