[DOCS-9265] 3.4: Clarify multiple fsyncLock behavior Created: 02/Nov/16  Updated: 26/Jul/18  Resolved: 29/Mar/18

Status: Closed
Project: Documentation
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Critical - P2
Reporter: James Wahlin Assignee: Kay Kim (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by DOCS-5976 fsyncLock documentation does not disc... Closed
Related
related to SERVER-6302 Race condition when multiple fsyncLoc... Closed
Participants:
Days since reply: 5 years, 45 weeks, 6 days ago
Story Points: 1

 Description   
Documentation Changes
  • Clarify that fsyncLock/fsyncUnlock tracks the number of open fsyncLocks. For example, fsyncLock(); fsyncLock(); fsyncUnlock(); stays locked.
  • Document lockCount field of return document.
Description

Currently (and historically) users could call fsyncLock multiple times which would then require the same number of fsyncUnlock calls to unlock the mongod instance. We should make this behavior clear in both our fsyncLock and fsyncUnlock documentation. I would recommend changing just for 3.4 as there exists a race condition that makes multiple lock/unlock unsafe prior to 3.4 (see SERVER-6302).

Additionally, with the fix for SERVER-6302 in 3.4 we added a "lockCount" field to the fsyncLock / fsyncUnlock result documents. This field contains the lock count after executing the command. In the fsyncUnlock case, a lockCount of "0" means the lock has been released and mongod can accept writes. We should reference this field and behavior in our documentation.



 Comments   
Comment by Githook User [ 29/Mar/18 ]

Author:

{'email': 'kay.kim@10gen.com', 'name': 'kay', 'username': 'kay-kim'}

Message: DOCS-9265, DOCS-5976: fsyncLock/Unlock and lock counts
Branch: v3.4
https://github.com/mongodb/docs/commit/deb8aa5bb4731f46c6d93b45acc723d79c4b4c21

Comment by Githook User [ 29/Mar/18 ]

Author:

{'email': 'kay.kim@10gen.com', 'name': 'kay', 'username': 'kay-kim'}

Message: DOCS-9265, DOCS-5976: fsyncLock/Unlock and lock counts
Branch: master
https://github.com/mongodb/docs/commit/de4e26dc99160a8e5024b5d7810dcd45089dc79a

Comment by James Wahlin [ 22/Nov/16 ]

andrew.aldridge - looks like DOCS-5976 is a partial-duplicate of this ticket.

Comment by Allison Reinheimer Moore [ 07/Nov/16 ]

To you for grooming, andrew.aldridge

Generated at Thu Feb 08 07:57:56 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.