You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enabling async with socket.io causes repeated disconnects and reconnects. Without async this works fine but my issue was that the program was delaying every 5 seconds if connection wasn't found. I believe the issue has to do with the code below. I noticed that cSessionId is empty (in both sync and async) at first but during sync, this value is somehow re-read below. But in async, the cSessionId is never set.
#if(WEBSOCKETS_NETWORK_TYPE != NETWORK_ESP8266_ASYNC)
} elseif(client->isSocketIO) {
if(client->cSessionId.length() > 0) {
DEBUG_WEBSOCKETS("[WS-Client][handleHeader] found cSessionId\n");
if(clientIsConnected(client) && _client.tcp->available()) {
// read not needed dataDEBUG_WEBSOCKETS("[WS-Client][handleHeader] still data in buffer (%d), clean up.\n", _client.tcp->available());
while(_client.tcp->available() > 0) {
_client.tcp->read();
}
}
sendHeader(client);
}
#endif
Maybe the issue is something else, but this is part of the error I am seeing with async on:
Enabling async with socket.io causes repeated disconnects and reconnects. Without async this works fine but my issue was that the program was delaying every 5 seconds if connection wasn't found. I believe the issue has to do with the code below. I noticed that cSessionId is empty (in both sync and async) at first but during sync, this value is somehow re-read below. But in async, the cSessionId is never set.
Maybe the issue is something else, but this is part of the error I am seeing with async on:
And with sync:
The text was updated successfully, but these errors were encountered: