Skip to content

gc: add range GC hint for efficient compaction of multi-range deletions #86550

@aliher1911

Description

@aliher1911

When fast path compaction is triggered, e.g. following a table drop, the whole range is deleted using a ClearRange operation. This operation triggers subsequent compaction in pebble which incurs additional processing cost that could be amortised if multiple clear range operations are processed together. With current MVCC GC, replicas are paced to reduce GC load on the system which is necessary when performing point GC operations, but this is doing a bad job for ClearRange type GC requests.

We can expedite GC of such replicas by adding hints to the ReplicatedRangeLocal keyspace so that GC queue could process all ranges together when fast path GC criteria for those ranges is met.

This hint key should be added by a separate request type and handled appropriately when doing range splits and merges.

Jira issue: CRDB-18812

Epic CRDB-2624

Metadata

Metadata

Assignees

Labels

A-kv-replicationRelating to Raft, consensus, and coordination.C-enhancementSolution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)GA-blockerbranch-release-22.2Used to mark GA and release blockers, technical advisories, and bugs for 22.2

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions