How does mongod handle multiple insert requests that arrive at the same time?

mysql queues multiple insert requests arriving at the same time one by one, maintaining a maximum of 1000 request queues.

does mongodb handle multiple insert requests arriving at the same time in the same way as mysql, or can multiple insert requests be inserted at the same time without queuing?

Mar.04,2021

also has queues, but WiredTiger locks are document-level, so the actual "lock" exists only when the request attempts to update the same document. The rest of the time is written to the database as quickly as possible. In general, unless there are hardware restrictions, the queue cannot be too long, and the empirical value is less than 10 in most cases. So there are only 128 reads and 128 writes inside the WT. Only the request to get the Ticket is possible to read and write.

Menu