[CSHARP-3815] Make SemaphoreSlimSignalable.Signal end SemaphoreSlimSignalable.WaitSignaledAsync immediately Created: 24/Aug/21 Updated: 15/Nov/21 Resolved: 06/Sep/21 |
|
| Status: | Closed |
| Project: | C# Driver |
| Component/s: | Internal |
| Affects Version/s: | None |
| Fix Version/s: | 2.14.0 |
| Type: | Improvement | Priority: | Unknown |
| Reporter: | Boris Dogadov | Assignee: | Boris Dogadov |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Description |
|
As an optimization for preventing WaitSignaledAsync task execution to continue on Signal thread, cancelation was scheduled on another thread with 0ms timeout. This introduced a race condition where WaitSignaledAsync can succeed despite being signaled. Eliminate this race condition and prevent WaitSignaledAsync to be resumed on Signal thread. |
| Comments |
| Comment by Githook User [ 06/Sep/21 ] |
|
Author: {'name': 'Boris', 'email': 'boris.dogadov@mongodb.com', 'username': 'BorisDog'}Message: |