- [Instructor] Around 2012,
a new class of databases came out,
the so-called NoSQL databases, such as MongoDB, Couchbase,
Redis, that's a key value store, CouchDB,
DynamoDB, that's a key value store as well, and Cassandra.
They're synonymic called NoSQL databases very often.
Actually, they have existed since the 1960s,
but they got very popular with the so-called Web 2.0.
As NoSQL databases are non-relational,
they usually have no integrity enforcement.
They are also not, by definition, ACID compliant.
And they are often a synonym for document databases,
but there are others like, for instance,
graph databases as well.
They're schema-less.
This means they have no predefined data structure
and they can basically store arbitrary data.
This also means that the schema management
moves into the application now
because somehow we still have to know
the structure of the database,
but now it's not enforced by the database management system.
With NoSQL databases, you have to take care of that yourself
within your application.
Let's look at our teacher subject example from before,
but now we are doing it with MongoDB.
So if you before had one table that held
the subject teacher relation
and one that had the teachers,
we now can create one collection for that
and Sina Patel's record, or document,
will now look like this.
So we have an ID, the name, the address,
and we see that MongoDB supports arrays as the value,
which means that we now can simply store the subject
she has insert this one record
and we don't need another database or relation for that.
And this also means that while MongoDB
does not support transactions,
Sina Patel's record can still be manipulated
in an atomic way.
In this course, we will be using
MongoDB as document database
and Redis as so-called key value store.
Key value stores are a specific subset of NoSQL databases,
but I will tell you more about that
in the respective chapter.