[SERVER-13585] Race in dist lock after winning "tournament" round Created: 14/Apr/14 Updated: 11/Jul/16 Resolved: 17/Apr/14 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Sharding |
| Affects Version/s: | 2.6.0 |
| Fix Version/s: | 2.7.0 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Randolph Tan | Assignee: | Randolph Tan |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||
| Operating System: | ALL | ||||
| Participants: | |||||
| Linked BF Score: | 0 | ||||
| Description |
|
Setup: Config0: T0 got this 2. T1 checks the current document at config0. , update is { ts: { $set: { ts: ts1 }}. , update is { ts: { $set: { ts: ts2 }}. But since T1 already updated the document, this update ends up modifying nothing. , update is set state to 1, ts to ts3. Now, both T2 and T3 thinks they have the lock! To reproduce this race more easily, simply add a sleepsecs(2) right on this line and run the sync6.js test: |
| Comments |
| Comment by Githook User [ 17/Apr/14 ] |
|
Author: {u'username': u'renctan', u'name': u'Randolph Tan', u'email': u'randolph@10gen.com'}Message: Remove the potential state transition from 1 to 0. |