You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix a race condition in MessageWriter.WriteMessage
This change fixes a race condition in MessageWriter.WriteMessage where
multiple calls to the method would end up writing at the same time. This
is due to the use of 'await' calls and happens even when both calls occur
on the same synchronization context. The subsequent calls proceed while
the first call is awaiting the completion of I/O writes.
The solution is to use an AsyncLock to synchronize I/O operations while
allowing more messages to be queued up.
0 commit comments