Netsend / mastersync

multi-master replication
GNU Affero General Public License v3.0
0 stars 1 forks source link

retry pull requests while disconnected #25

Closed timkuijsten closed 9 years ago

timkuijsten commented 9 years ago

currently a pull request is sent once the server is started but it is never retried on failure.

Implement a scheme that supports retrying to login a disconnected pull request that also covers recovering disconnceted connections.

Use a binary exponential backoff algorithm that initially waits 1 second up to a configured maximum (i.e. 7200 seconds) on continuous failure.

s = 2^t where t is the number of the login attempt and s is the number of seconds to wait for any next attempt (if the current attempt failed). On successful login this counter should be reset.