[SERVER-6364] Remove/replace write lock in replAuthenticate() Created: 09/Jul/12 Updated: 19/Mar/13 Resolved: 11/Mar/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Security |
| Affects Version/s: | 2.0.6, 2.1.2 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Ben Becker | Assignee: | Unassigned |
| Resolution: | Done | Votes: | 0 |
| Labels: | Authentication., ReplSet | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
All |
||
| Issue Links: |
|
||||||||
| Participants: | |||||||||
| Description |
|
In repl.cpp (L1056 in r2.0.2; L1069 in master), we take a write lock before calling findOne() or getSingleton(). There doesn't seem to be a reason for taking a write lock here; replacing with a read lock seems to make sense. |
| Comments |
| Comment by Ben Becker [ 11/Mar/13 ] |
|
Issue was resolved by |
| Comment by Eric Milkie [ 11/Mar/13 ] |
|
The line in question seems to have already been switched to a ReadContext sometime prior to version 2.2. |