tidwall / SwiftWebSocket

Fast Websockets in Swift for iOS and OSX
MIT License
1.53k stars 244 forks source link

the library is very slow #127

Open druidvfx opened 6 years ago

druidvfx commented 6 years ago

Sorry for my English

the library is very slow!!! With a large data stream, the delay of packets reaches 1-10 minutes

I ran parallel objective-c + socketRocket and swift + SwiftWebSocket

bitfinex data stream trades from https://docs.bitfinex.com/v2/reference#ws-public-trades

  1. objective-c + socketRocket, 10 simultaneous sockets for each trading pair - maximum packet delay two seconds with large data stream. data stream ten times more than swift + SwiftWebSocket

  2. swift + SwiftWebSocket, one socket one trading pair - maximum packet delay 10 minutes!!!! With a small data stream there are no delays on swift + SwiftWebSocket As soon as the data stream becomes small, everything starts to flow again