Using Spring Data MongoDB for persistence
This section will introduce MongoDB, and how to use Spring Data MongoDB repositories to provide Create, Retrieve, Update, and Delete (CRUD) operations on MongoDB easily.
Understanding MongoDB
MongoDB is a free and open source document store that stores data in a schemaless JSON format that is highly flexible. Each individual document can have different fields. It allows ad-hoc querying, indexing, and aggregation out of the box.
MongoDB can provide high availability, horizontal scalability (scale out), and geographical distribution. MongoDB simplifies development by providing drivers in multiple programming languages, such as C++, C#, JavaScript, Java, and so on.
The following are some of the features of MongoDB:
- High availability with built-in replication
- Horizontal scalability with sharding
- End-to-end security
- Document validation and schema exploration
Understanding Spring Data MongoDB
The Spring Data MongoDB project was intended to introduce the concepts...