[SERVER-58489] Collection creation stuck in an infinite writeConflictRetry loop when having a duplicate name as a view Created: 13/Jul/21  Updated: 29/Oct/23  Resolved: 14/Jul/21

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 5.0.1, 5.1.0-rc0

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

Issue Links:
Backports
Depends
Related
is related to SERVER-57061 Concurrent writers can create a Colle... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v5.0
Sprint: Execution Team 2021-07-26
Participants:
Linked BF Score: 147

 Description   

When creating a collection implicitly, we check if a collection with the namespace string already exists. However, before committing, we also check that if the nss conflicts with another view. As a result, if one thread successfully creates a view while another one is attempting to create a collection with the same nss in the writeConflictRetry loop, the other thread could fall into an infinite loop.



 Comments   
Comment by Vivian Ge (Inactive) [ 06/Oct/21 ]

Updating the fixversion since branching activities occurred yesterday. This ticket will be in rc0 when it’s been triggered. For more active release information, please keep an eye on #server-release. Thank you!

Comment by Githook User [ 15/Jul/21 ]

Author:

{'name': 'Yuhong Zhang', 'email': 'danielzhangyh@gmail.com', 'username': 'YuhongZhang98'}

Message: SERVER-58489 Collection creation stuck in an infinite writeConflictRetry loop when having a duplicate name as a view

(cherry picked from commit c7727a3f407d4f7552df443ff6c81e4f7d6f3fe2)
Branch: v5.0
https://github.com/mongodb/mongo/commit/07885366872b8c511dcde4450ed339961a8168a2

Comment by Githook User [ 14/Jul/21 ]

Author:

{'name': 'Yuhong Zhang', 'email': 'danielzhangyh@gmail.com', 'username': 'YuhongZhang98'}

Message: SERVER-58489 Collection creation stuck in an infinite writeConflictRetry loop when having a duplicate name as a view
Branch: master
https://github.com/mongodb/mongo/commit/c7727a3f407d4f7552df443ff6c81e4f7d6f3fe2

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