Marfusios / bitfinex-client-websocket

🛠️ C# client for Bitfinex & Ethfinex websocket API version 2.0
Apache License 2.0
55 stars 38 forks source link

Aborted State #20

Closed N-0x90 closed 5 years ago

N-0x90 commented 6 years ago

Hello,

In some cases the socket goes to Abort state and then nothing works again, cant reconnect...

Here full log https://pastebin.com/nM9GQ1ZE

All start in [08:27:00 ERR] [BFX WEBSOCKET COMMUNICATOR] Error while listening to websocket stream

I'm still no catch where this happen...

Marfusios commented 6 years ago

@Ox90 Hello, thanks for reporting an issue. I've finally figured out what's going on. You are using the library inside WinForms application, which is based on a full .NET Framework. And WebSockets implementation differs between .NET Core and .NET Framework. The issue is with parallel sending, ClientWebSocket doesn't support it.

I've fixed an issue in the version 1.0.37. There is an implementation of the producer-consumer pattern, every message is inserted into a queue before actual sending. Please try and let me know if everything works.