I'm trying to implement websockets between a B4J client and a B4J server. this goes well, but I need some heartbeat mechanism so a connection drop is detected and the connection remade.
Implementing this with ping-pong messages and timers really gets messy an not workable (websockets not being cleared, ...)
I know there are reconnect websockets in a webbrowser implementation, but how to do this in B4J/B4I/B4A <-> B4J communication ?
Thanks, but I could not create a 100% failsafe solution.
Instead I poll the server now every few minutes and launch a websocket each time in between. So if the websocket drops, a new one will be reconnected after this interval.