[SERVER-48549] createIndexes command unsafely accesses collection object outside of lock Created: 02/Jun/20  Updated: 29/Oct/23  Resolved: 03/Jun/20

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 4.4.0-rc9, 4.7.0

Type: Bug Priority: Major - P3
Reporter: Louis Williams Assignee: Louis Williams
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.4
Sprint: Execution Team 2020-06-15
Participants:
Linked BF Score: 14

 Description   

This code is not safe because we are not holding a collection lock while using a collection object from the catalog. In some circumstances, this could be safe, but there is no guarantee that the collection we are accessing even exists.



 Comments   
Comment by Githook User [ 03/Jun/20 ]

Author:

{'name': 'Louis Williams', 'email': 'louis.williams@mongodb.com', 'username': 'louiswilliams'}

Message: SERVER-48549 createIndexes must not access collection outside of lock

(cherry picked from commit eab3da634bc745c25c7dd38c07e4911e81020e04)
Branch: v4.4
https://github.com/mongodb/mongo/commit/f9df74846d8fd8e9c9530d0b53df4a222c255378

Comment by Githook User [ 03/Jun/20 ]

Author:

{'name': 'Louis Williams', 'email': 'louis.williams@mongodb.com', 'username': 'louiswilliams'}

Message: SERVER-48549 createIndexes must not access collection outside of lock
Branch: master
https://github.com/mongodb/mongo/commit/eab3da634bc745c25c7dd38c07e4911e81020e04

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