Shocky
Shocky copied to clipboard
Occasionally send PINGs to the server to test if the connection is still alive
Occasionally send "PING :" + UUID.randomUUID().toString() (see here) to the server to test if the connection is still alive, and if you get no PONG after ~100 seconds, reconnect.