robut
robut copied to clipboard
Reconnect on failures
From the xmpp4r docs:
If you want your connection to survive disconnects and timeouts, catch exception in Stream#on_exception and re-call Client#connect and Client#auth. Don‘t forget to re-send initial Presence and everything else you need to setup your session.
Big +1. I may take a crack at this this week.
I fixed by far our most common crash (UTF-8 characters) but this would still be really nice to have.
I've got Robut running on a MacMini in our office. We're using launchd to make sure Robut runs when the system boots, and restart it on failure, etc...
However, Robut will occasionally get disconnected (not sure why, and nothing shows up in the logs), and then I have to manually restart the service to get it to reconnect. Launchd doesn't help here as it the service doesn't "fail", it just disconnects. Auto-reconnecting on failure would go a long way to keeping our Robut up and running.