Do not age out no-op peer recovery retention leases #47905
Labels
:Distributed/Recovery
Anything around constructing a new shard, either from a local or a remote source.
>enhancement
Team:Distributed
Meta label for distributed team
We remove peer recovery leases belonging to unavailable nodes following these rules:
index.soft_deletes.retention_lease.period
time has passed.If the index is no longer receiving any updates and the lease does not really retain any operations (retaining-seq-no >= gcp+1), it seems desirable to keep the retention lease until all shards are started (regardless of retention period). This would ensure that a no-op recovery can happen rather than a file based recovery.
This will only affect edge cases where either there is no extra node to assign the shard to or allocation has been disabled for more than 6h (with default values). Also, the benefit is small to non-existent if the shards have already been undergoing a file based recovery. Still, the change is simple and could be beneficial so seems worthwhile doing.
The text was updated successfully, but these errors were encountered: