Open gribunin opened 8 years ago
Any news about this pull request? I had experienced the same problem while testing my webserver with jMeter.
I made a quick and dirty fix removing this line But I don't know any possible consequences.
Hello, I have the same problem, is there any update on this?
I'm working on a new network stack. Completely async and rewritten from scratch.
_readSemaphore has been replaced with _readEvent, because an event can be safely Set multiple times in a row, while semaphore can be unintentionally Release'ed beyond its maximum level. When server sends messages faster than the client reads, and OnChannelMessageReceived is called while ReceiveAsync is still executing, the _readSemaphore is Release'ed twice -- first in on OnChannelMessageReceived, then second time at the end of ReceiveAsync (because readItems.Count > 0) which lead to unhandled SemaphoreFullException in ReceiveAsync
The offending data flow: