1. Course Outline
This course explains the relevant content of MongoDB data update. Contains the basic use of the Insert function for inserting documents, removing the Remove function from the document, and updating the update function for the document. Besides. It also introduces the writing security mechanism of MongoDB, the bulk write bulk function and so on.
- MongoDB Document Insertion and deletion
- MongoDB Document Churn
- MongoDB's write security mechanism
2. Course Introduction
In this lesson, we will start with a brief introduction to MONGODB Data Update in general. It then introduces the document insertion function insert, the bulk update function of the document BULK, and the document removal function, remove, and finally the memory allocation policy of the MMAPV1 storage engine.
Data operations of the database are divided into two major categories: Data update and data query, this lesson mainly explains MongoDB data update, in the next lesson will introduce MongoDB data query.
MongoDB uses the MMAPV1 storage engine by default, which stores records on disk in the order in which they are written.
For the MMAPV1 storage engine, if an update operation exceeds the current pre-allocated space on disk, MongoDB allocates a larger contiguous space on disk again. The original data is then copied to the newly allocated memory. The whole process will take a lot of time. In particular, the set of indexes created will take a lot of other time. Because it is assumed that a collection exists at the same time as the data is replicated. The appropriate index content must be updated. So on a collection with multiple indexes, it is very time consuming to allocate memory again and again, which can seriously reduce the write efficiency of the system.
3. Specific Course Videos
Video course links such as the following: MongoDB Data update
Lesson three MongoDB Data update