[SERVER-62571] Serialize concurrent accesses to `Socket` in `ThrowOnNetworkErrorInEnsureSync` Created: 12/Jan/22 Updated: 20/Nov/23 Resolved: 13/Jan/22 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Internal Code |
| Affects Version/s: | None |
| Fix Version/s: | 5.3.0, 5.2.2 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Amirsaman Memaripour | Assignee: | Amirsaman Memaripour |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | servicearch-wfbf-day | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||
| Operating System: | ALL | ||||||||||||||||
| Backport Requested: |
v5.2, v5.0
|
||||||||||||||||
| Sprint: | Service Arch 2022-1-24 | ||||||||||||||||
| Participants: | |||||||||||||||||
| Linked BF Score: | 69 | ||||||||||||||||
| Story Points: | 1 | ||||||||||||||||
| Description |
|
The main thread attempts to close the socket (here), while the connection thread is running setsockopt on the socket (here). We need to serialize accesses to the socket object to fix the data-race. This is almost identical to the issue reported in |
| Comments |
| Comment by Githook User [ 01/Mar/22 ] |
|
Author: {'name': 'Amirsaman Memaripour', 'email': 'amirsaman.memaripour@mongodb.com', 'username': 'samanca'}Message: (cherry picked from commit 1b71c67c9290af3db02d75471eeba894862e1a31) |
| Comment by Githook User [ 13/Jan/22 ] |
|
Author: {'name': 'Amirsaman Memaripour', 'email': 'amirsaman.memaripour@mongodb.com', 'username': 'samanca'}Message: |