[SERVER-59851] Investigate whether BSON depth validation logic can be consolidated Created: 09/Sep/21  Updated: 20/Oct/21  Resolved: 20/Oct/21

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Gregory Noma Assignee: Gregory Noma
Resolution: Duplicate Votes: 0
Labels: techdebt
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates SERVER-60158 Generalize BSONObj traversal code fro... Open
Related
related to SERVER-58777 Inserts and updates disagree on wheth... Closed
Sprint: Execution Team 2021-11-01
Participants:

 Description   

Currently we have two separate implementations to validate the depth of a BSON object: one used by inserts and one used by updates. This can lead to discrepancies like the one described in SERVER-58777. Thus it may be valuable to determine whether it would be possible to consolidate these two implementations into one.

However, this may not be possible due to performance reasons. In particular, the update path uses mutablebson to do the traversal whereas the insert path does not..



 Comments   
Comment by Gregory Noma [ 20/Oct/21 ]

Going to close this in favor of SERVER-60158, which should cover this plus more general cases as well.

Generated at Thu Feb 08 05:48:19 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.