[SERVER-48200] Audit and fix session->open_cursor calls to handle EBUSY Created: 13/May/20  Updated: 29/Oct/23  Resolved: 19/May/20

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

Type: Bug Priority: Major - P3
Reporter: Eric Milkie Assignee: Backlog - Storage Execution Team
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Assigned Teams:
Storage Execution
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Execution Team 2020-06-01
Participants:
Linked BF Score: 16

 Description   

After we removed Collection locking for oplog readers (they only need Global IS), this stopped protecting such readers from concurrent validate commands locking the WiredTiger oplog collection's table with calls to WT verify(). Thus, open_cursor() can now return EBUSY, but only for the oplog collection. This is captured and handled for most cursor usage via WiredTigerSession's cursor cache, but we also have some internal code in wiredtiger_kv_engine.cpp and wiredtiger_record_store.cpp that bypasses this and calls open_cursor() themselves. These callers need to also check for EBUSY.



 Comments   
Comment by Githook User [ 19/May/20 ]

Author:

{'name': 'Eric Milkie', 'email': 'milkie@10gen.com', 'username': 'milkie'}

Message: SERVER-48200 RandomCursor should explicitly check for EBUSY when opening a WT cursor
Branch: master
https://github.com/mongodb/mongo/commit/bd04cc801768df02a4b8688753e42e0e6f90cfa8

Comment by Eric Milkie [ 18/May/20 ]

There is only one place to fix now; for RandomCursor.

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