Skip to content

Improve lease management for mutables

Fixes #221 (closed)

The old behavior:

  • If an arbitrarily selected existing share in a slot where a write is happening has an unexpired lease, no share written by the operation will have a lease added or renewed (including new shares, which therefore end up with no lease at all).
  • If existing shares have unexpired leases then the client counts the excess value of those leases as credit towards the operation it is performing but the server only counts them if they are being written to and so clients under-fund certain write operations.

The new behavior:

  • A mutable write will add leases to or renew leases on exactly the set of shares which have no unexpired leases and are also being written to.
  • The server takes all shares in the slot into account when determining the number of additional passes the client must spend to complete the operation so that it comes to the same conclusion as the client about how many passes are required.

Merge request reports