1 Introduction
This article provides an introduction to Azure Cosmos DB - Document API with MongoDB. It mainly focuses on NoSQL - non-relational databases. Let's explore MongoDB - document database and finally move into Microsoft's latest web scale database innovation
which is Azure Cosmos DB.
2 What is NoSQL
NoSQL is the next generation database, In the world of databases, we have SQL & NoSQL databases, relational & non-relational, NoSQL means "not only SQL".
The difference between these two types of database technologies is, what type of data they store, how they store it and the way we use it. Relational databases are structured like a phone book that stores phone numbers. Non-relational databases are document
based & distributed like folders that hold everything from phone numbers to images.
NoSQL databases are non-relational, A non-relational data model doesn't have a table model, Instead, data can be stored in a single document file. In a relational database, data is organized into tables and each table has columns and data rows.
Relational databases are dominated the software industry for a long time, But now non-relational databases are taking its place.
An important feature of NoSQL database is polyglot persistence, polyglot persistence means. we can use more than one storage mechanism to accomplish application storage needs.
NoSQL databases are scalable, they can scale up to thousands and millions of users.
Most of the NoSQL databases are open source, You can just download them and setup a test environment.
NoSQL databases are schema free, In NoSQL database technology, no predefined structure, no schema
It has easy replication support, When you have more customers via web & mobile, availability becomes a major concern. In a relational database deployed to a single physical server, if it fails database becomes unavailable. But NoSQL databases, partitions
and distributes data into multiple database instances, The data can be replicated to one or more instances for high availability. If you use Oracle software, it requires separate software to replicate data, but with NoSQL, we don't need anything extra.
NoSQL has a simple API, When it comes to relational databases like SQL, It's not compatible with Java, Php or Python. But NoSQL databases, they have overcome this issue with their available APIs. When you use a NoSQL database technology, you don't need to
understand about the underlying architecture of their system.
The relational data structure & in memory data structure of the application is different in SQL. When you use a NoSQL database, developers don't need to convert in memory structure of data to a relational structure, storage need for an ERP application is
different from a storage need for facebook or twitter.
NoSQL supports for a huge amount of data, for modern web scale applications, you have millions of data from millions of customers., so better to go for NoSQL database technology.