facebook / facebook/rocksdb

Mempurge garbage bytes ticker does not consider some value types or data written to blob files

Open
#9,011 2 comments 0 reactions 0 assignees View on GitHub
bug up-for-grabs
Dominant language
C++
Stars
32.1k
Forks
6.9k
Avg merge
32m
Merged PRs (30d)
1

Description

rocksdb.memtable.garbage.bytes.at.flush is outdated bytes of data present on memtable at flush time.

It is calculated by total_payload_bytes - total_payload_bytes_written.

https://github.com/facebook/rocksdb/blob/6c3bf83d6fc1f599e31b94d7a3c370dce7d36273/db/builder.cc#L275

total_payload_bytes_written is the bytes writes to SSTs. When BlobDB is enabled , However, the values write to blob file will also be considered as garbage.

Contributor guide

Open the contributing guide

Research direction

Start at db/builder.cc around the calculation of rocksdb.memtable.garbage.bytes.at.flush, then trace how total_payload_bytes and total_payload_bytes_written are updated when BlobDB is enabled. Done means the ticker accounts for values written to blob files and the other value types identified by the issue, with behavior verified by the relevant existing tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.