File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -116,9 +116,20 @@ improve concurrency. MongoDB groups batches by namespace (:ref:`MMAPv1
116
116
operations using a different thread. MongoDB always applies write
117
117
operations to a given document in their original write order.
118
118
119
- While applying a batch, MongoDB blocks all read operations. As a
120
- result, secondary read queries can never return data that reflect a
121
- state that never existed on the primary.
119
+ .. versionchanged:: 4.0
120
+
121
+ Starting in MongoDB 4.0, read operations that
122
+ :ref:`target secondaries <replica-set-read-preference>` and are
123
+ configured with a :ref:`read concern<read-concern>` level of
124
+ :readconcern:`"local"` or :readconcern:`"majority"` will now read from
125
+ a :ref:`WiredTiger<storage-wiredtiger>` snapshot of the data if the read
126
+ takes place on a secondary where replication batches are being applied.
127
+ Reading from a snapshot guarantees a consistent view of the
128
+ data, and allows the read to occur simultaneously with the ongoing
129
+ replication without the need for a lock. As a result, secondary reads
130
+ requiring these read concern levels no longer need to wait for
131
+ replication batches to be applied, and can be handled as they are
132
+ received.
122
133
123
134
Pre-Fetching Indexes to Improve Replication Throughput
124
135
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
You can’t perform that action at this time.
0 commit comments