I am using WebSocketSharp
to receive a stream from a service in C#. So basically I have some code like this.
WebSocket webSocket = new WebSocket("wss://ws-feed....");
webSocket.Connect();
webSocket.Send("message");
//Do something
//Data still being received
Console.Write("What happens if I break indefinitely here?");
What I am wondering is what happens to messages received while the WebSocket
is in a long breakpoint for instance at the last line in the above example?
I assume it is implementation specific but based on my observations it appears that messages are queued and released once the breakpoint is exited. However I assume there must be some cap on how many messages can be queued prior to messages starting to be dropped.
So, what is the typical behavior of a WebSocket
library while it has encountered a breakpoint? Are messages indefinitely queued or will they eventually be dropped? Should any specific precautions be taken while debugging to ensure you are seeing the data as it would behave in release mode?