waitUntilDurable currently holds a mutex across calls to JournalListener::getToken and JournalListener::onDurable calls. The mutex does not appear necessary for the JournalListener functions. The mutex appears to be for accessing the _journalListener because it can be asynchronously set by another caller via the setJournalListener function on the class.
Removing the mutex will allow the existing promises in the code comments to become true, which are not currently true because the mutex serializes callers.
Furthermore, I need to add a write in getToken for the Replicate Before Journaling project, and I don't want to take a mutex before collection locks: removing the mutex simplifies the code changes.
- is depended on by
-
SERVER-44555 Implement replicate before journaling
- Closed
- related to
-
SERVER-80432 waitForSession can miss JournalListener onDurable calls
- Closed
-
SERVER-80657 clean up JournalListener access in WiredTigerSessionCache::waitUntilDurable
- Closed