MongoDB & NoSQL (50 Qs)•Part 2: Core Architecture & Implementation (Mid-Level)
What is Read Concern (`local`, `available`, `majority`, `linearizable`)?
senior LevelSystem Design
In Simple Words: Controls the consistency and isolation of data returned by read operations:
local(Default): Returns data from the node responding to the query without verifying if the data has been committed to a majority of nodes.majority: Returns data that has been acknowledged by a majority of replica set nodes (guarantees data cannot be rolled back).linearizable: Real-time strong consistency; waits for concurrent writes and verifies primary status with peers before returning.