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
When we run the bot and there's a disconnct, we have a retry in place to attempt a "resume" with discord.
The way this works is by using an exponential backoff i.e. try again after 2 seconds, then 4, then 8 etc.
Reconnecting in 4000ms [attempt=1]
Reconnecting in 8000ms [attempt=2]
...
This use to work but with all the refactoring, something broke somewhere.
Repro steps:
Start the bot
Disconnect your internet
Reconnect your internet
The following will start spamming in the console:
14:49:06.702 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketRetryHandler - Reconnecting in 8000ms [attempt=2]
14:49:14.919 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketManager - Connected to Discord
14:49:18.738 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketRetryHandler - Reconnecting in 2000ms [attempt=0]
14:49:18.739 [vert.x-eventloop-thread-0] ERROR com.javadiscord.jdi.internal.gateway.WebSocketHandler - [1000] null
14:49:18.824 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketManager - Connected to Discord
14:49:20.935 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketManager - Connected to Discord
14:49:22.159 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketRetryHandler - Reconnecting in 2000ms [attempt=0]
14:49:22.159 [vert.x-eventloop-thread-0] ERROR com.javadiscord.jdi.internal.gateway.WebSocketHandler - [1000] null
14:49:22.241 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketManager - Connected to Discord
14:49:24.345 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketManager - Connected to Discord
14:49:24.665 [vert.x-eventloop-thread-0] INFO com.javadiscord.jdi.internal.gateway.WebSocketRetryHandler - Reconnecting in 2000ms [attempt=0]
14:49:24.665 [vert.x-eventloop-thread-0] ERROR com.javadiscord.jdi.internal.gateway.WebSocketHandler - [1000] null
Observations
We're reconnecting and resuming our session with discord correctly.
The error string [1000] null comes from WebSocketHandler#frameHandler
When we run the bot and there's a disconnct, we have a retry in place to attempt a "resume" with discord.
The way this works is by using an exponential backoff i.e. try again after 2 seconds, then 4, then 8 etc.
This use to work but with all the refactoring, something broke somewhere.
Repro steps:
The following will start spamming in the console:
Observations
We're reconnecting and resuming our session with discord correctly.
The error string
[1000] null
comes fromWebSocketHandler#frameHandler
Relevant classes that this error is around:
com.javadiscord.jdi.internal.gateway.WebSocketRetryHandler
com.javadiscord.jdi.internal.gateway.WebSocketManager
com.javadiscord.jdi.internal.gateway.WebSocketHandler
Acceptance Criteria
WHEN connected to discord
AND the internet disconnects
THEN we should successfully be connected to discord without any errors showing up
The text was updated successfully, but these errors were encountered: