kerryjiang / WebSocket4Net

A popular .NET WebSocket Client
752 stars 272 forks source link

Multiplex Web Socket support #120

Open siberianguy opened 6 years ago

siberianguy commented 6 years ago

I'm implementing a client for Binance Api and I have to connect to multiple endpoints wss://stream.binance.com:9443/ws/currency@kline_1m. There could be multiple values instead of currency, so currently I have to deal with multiple WebSocket instances which gets tricky. As I understand, some WebSocket implementations support multiplex connection, so my situation could be handled using one WebSocket instance. Is this the case for WebSocket4Net?

kerryjiang commented 6 years ago

This information is sent through websocket connection handshake which only happens when the connection start to establish. Of course you can create multiple websocket instances to connect to different URLs.