[SERVER-13420] the notifier and syncSourceFeedback threads can reach a deadlock Created: 31/Mar/14 Updated: 11/Jul/16 Resolved: 01/Apr/14 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | 2.6.0-rc2 |
| Fix Version/s: | 2.6.0-rc3 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Matt Dannenberg | Assignee: | Matt Dannenberg |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Operating System: | ALL |
| Participants: |
| Description |
|
In connectOplogNotifier, the notifier thread grabs bgsync's _mutex and then calls syncSourceFeedback.connect() which grabs SyncSourceFeedback's _mtx and _connmtx. Meanwhile SyncSourceFeedback's run() loop grabs its _mtx and _connmtx and then calls bgsync's getSyncTarget() which grabs bgsync's _mutex. If each of these threads grabs their first lock, we end up deadlocked. |
| Comments |
| Comment by Githook User [ 01/Apr/14 ] |
|
Author: {u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}Message: (cherry picked from commit 26f3c3140d6c49732d3462235d9dd496e17c504f) |
| Comment by Githook User [ 01/Apr/14 ] |
|
Author: {u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}Message: |