Skip to content

Renter resync

Luke Champine requested to merge renter-sync into master

The renter and host can "desynchronize" if a disconnect occurs at a specific part of the revision protocol. Specifically, if the renter disconnects after sending the revision to the host, but before receiving the host's signatures, it will not know for sure whether the host has applied the revision or not.

One solution to this would be for the host to accept references to either the "current" or "previous" revision (according to the host). However, this requires the host to store up to one additional segment per contract.

An alternative (implemented here) is for the renter to save the revision to disk before sending it to the host for approval. If a disconnect then occurs and the renter reconnects, it will first attempt to synchronize with the "old" revision, and then try the "new" revision if that fails. Note that no additional storage requirement is imposed here, because the renter is not the party storing the data.

Merge request reports