Skip to content

kvserver: limit concurrent lease requests #100426

@erikgrinaker

Description

@erikgrinaker

When #98433 lands, we should consider limiting the number of concurrent lease requests in flight, since we'll be extending 1/6 of all local leases every 500 ms, probably by using a semaphore during requestLease(). However, prioritization can be a bit tricky here -- for example, we probably want lease acquisitions that's blocking foreground traffic to take precedence over lease extensions for mostly-idle ranges.

We can also consider having a bounded goroutine pool for lease requests, instead of spawning new goroutines for these.

Jira issue: CRDB-26429

Epic CRDB-25207

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-performancePerf of queries or internals. Solution not expected to change functional behavior.T-kvKV Team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions