Enhancement: Automatic and periodic renew of Key lease for basic Put operation

Open
#65 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
28/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
go

Research direction

Start by reading the existing Lock() lease-renewal flow and the Consul PeriodicRenew session implementation, then trace how basic Put is implemented across supported backends. Done means Put can keep a key lease renewed while the client runs and provides a way to stop renewal, with behavior consistent across the supported backends.

Written by the indexing model from the issue text.

Description

kind/enhancement store/meta

libkv should allow to automatically renew the lease for a key (using TTLs) as long as the client is still up and running. We may want to return a stopChan to stop the process of automatically renewing the key if needed.

The same way we have PeriodicRenew of sessions using Consul, it can be useful to not explicitely invoke a renewTTL every T interval time but just know that the key lives until the client dies and the TTL expires.

Some work has been done for the Lock() call which automatically renew the lease for a Key to keep the lock under custody. If a signal is sent to the stopChan, the Lock process stops renewing the TTL and/or Unlocks the key. This work should be extended for the basic Put operation of supported backends.

Dominant language
Go
Stars
847
Forks
204
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from docker/libkv

All issues in docker/libkv

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.