I am writing a file synchronization client (in Java 1.6) that uses Sardine:
https://code.google.com/p/sardine/
When Sardine loses connection to the server (ie. network outage or change from LAN to WiFi), I am unable to reconnect until I completely stop the client and start it back up again.
I've tried the following:
- spamming the connection
- re-creating the Sardine object dynamically
- re-packaging Sardine source code with latest Apache HTTP libs
As far as I can tell the actual networking takes place within AbstractHttpClient, but I am not sure what to try next.
Any suggestions on how I can make this thing re-connect dynamically regardless of the reason?