[SERVER-42213] ephemeralForTest cursors need to be made thread_safe Created: 12/Jul/19 Updated: 27/Oct/23 Resolved: 04/Nov/19 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Storage |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Matthew Russotto | Assignee: | Eric Milkie |
| Resolution: | Works as Designed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Operating System: | ALL | ||||||||||||
| Sprint: | Execution Team 2019-11-04 | ||||||||||||
| Participants: | |||||||||||||
| Linked BF Score: | 14 | ||||||||||||
| Description |
|
The EphemeralForTestRecordStore uses a mutex to control access to its _data->records member. However, EphemeralForTestRecordStore::Cursor and ::ReverseCursor get a direct reference to this member and do not lock the mutex when accessing it. Furthermore, these classes cache an iterator to the structure, which is a std::map; in the case of a rollback these iterators will be invalid, and in the case of a delete they might be. |
| Comments |
| Comment by Eric Milkie [ 04/Nov/19 ] |
|
The build failure was fixed with |
| Comment by Eric Milkie [ 20/Aug/19 ] |
|
Waiting for linked SERVER ticket to be diagnosed and fixed. |
| Comment by Eric Milkie [ 26/Jul/19 ] |
|
We should do something to stem the failures caused by this issue. |