There is a problem with reconnecting to the server using websockets.
How to reproduce the issue:
Use web sockets to connect with your server.
Turn off your internet connection.
CocoaMQTT does not establish a connection, although does not inform about an issue.
Turn on the internet connection. CocoaMQTT will never reconnect again.
I think scheduleRead method should be called just after establishing a web socket connection. Then we can receive errors like "no internet connection". Calling scheduleRead in didOpenWithProtocol is too late for those initial errors.
There is a problem with reconnecting to the server using websockets.
How to reproduce the issue:
I think
scheduleRead
method should be called just after establishing a web socket connection. Then we can receive errors like "no internet connection". Calling scheduleRead in didOpenWithProtocol is too late for those initial errors.