Details
-
Task
-
Resolution: Unresolved
-
Major - P3
-
None
-
None
-
None
-
None
-
Storage Execution
Description
This ensures the bucket document wasn't changed underneath us while generating the DocDiff from something like a direct write or synchronization bug in the BucketCatalog. This mechanism protects against data corruption.
Rough draft of how we can achieve this:
- When committing a WriteBatch
- We have a Struct {anchor, preImageBytes, postImageBytes}. The bytes are after the anchor point
- Before inserting measurements into the builders, set the anchor and preImageBytes for each data field
- Insert measurements into the builders from the WriteBatch
- Set the postImageBytes
- Generate the DocDiff using the anchor as o(ffset) and postImageBytes as d(ata)
- Pass this DocDiff into UpdateCommandRequest with preImageBytes.
- In the query layer, we check that the current bucket document preImageBytes match after the anchor
This is a primary only check
Attachments
Issue Links
- depends on
-
SERVER-79416 Generate and apply the BSONColumn DocDiff from the bucket catalog
-
- Open
-