Skip to content

fix: reset stale TTL on reused FlushRecord and bump rocksdb-cloud roll guard - #552

Merged
thweetkomputer merged 2 commits into
mainfrom
update-rocksdb-cloud-roll-guard
Aug 11, 2026
Merged

fix: reset stale TTL on reused FlushRecord and bump rocksdb-cloud roll guard#552
thweetkomputer merged 2 commits into
mainfrom
update-rocksdb-cloud-roll-guard

Conversation

@thweetkomputer

@thweetkomputer thweetkomputer commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Two changes:

  • Bump third_party/src/rocksdb-cloud to 7b4210e (eloqdata/rocksdb-cloud main), which publishes the smallest-file-number guard object in RollNewCookie before the new epoch becomes reachable (Upgrade github workflow DoozyX/clang-format-lint-action to v0.18 #20) and fixes the const-qualification compile error in PutSmallestFileNumberObject ([Feature]: Move table stats broadcast into data sync worker #21).
  • Fix silent data loss on RocksDB(-Cloud) backends: FlushRecord::SetNonVersionedPayload reuses its BlobTxRecord across data-sync scan batches but only cleared value_, leaving the previous record's ttl_ behind. A no-TTL object flushed into a contaminated slot was written to the KV store with another key's expiration, so the read path and the TTL compaction filter treated it as expired and the key disappeared once evicted from memory — no restart required. Reset ttl_ to UINT64_MAX (the "no TTL" sentinel) on every reuse.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Bug Fixes

    • Corrected expiration handling when records without a time-to-live are reused, preventing stale expiration settings from affecting data.
  • Chores

    • Updated the underlying storage infrastructure to a newer revision.
    • Incorporated upstream maintenance and improvements while preserving existing functionality.

@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown

Review Change Stack

Walkthrough

The PR updates the rocksdb-cloud submodule reference and resets stale TTL metadata when BlobTxRecord payloads are reused without versioning.

Changes

RocksDB Cloud update

Layer / File(s) Summary
Update submodule pointer
third_party/src/rocksdb-cloud
The submodule reference advances to commit 7b4210e7351a961a7fc2196c0ecfc81d01be3ac8.

Blob TTL reset

Layer / File(s) Summary
Reset reused blob TTL
tx_service/include/cc/cc_entry.h
SetNonVersionedPayload resets the reused BlobTxRecord TTL to UINT64_MAX after clearing the previous value.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

Suggested reviewers: liunyl

Poem

A rabbit resets a stale TTL,
Then hops where cloud commits dwell.
Old payloads leave no trace behind,
A newer pointer leads the bind.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the changes and behavior impact but omits most required template sections, including tests, risks, rollback, reviewer guidance, and follow-up work. Add the required sections with test commands and results, risk and rollback details, reviewer guidance, and explicit follow-up status.
✅ Passed checks (4 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly summarizes both changes: the stale TTL fix and the rocksdb-cloud submodule update.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch update-rocksdb-cloud-roll-guard

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

thweetkomputer and others added 2 commits August 11, 2026 06:43
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
FlushRecord::SetNonVersionedPayload reuses the BlobTxRecord slot across
data-sync scan batches but only cleared value_, leaving the previous
record's ttl_ behind. A no-TTL object flushed into a contaminated slot
was then written to the KV store with another key's expiration: the
RocksDB(-Cloud) read path and TTL compaction filter treat it as expired,
so the key silently disappears once it is evicted from memory. Reset
ttl_ to UINT64_MAX (BlobTxRecord's "no TTL" sentinel) on every reuse.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@thweetkomputer
thweetkomputer force-pushed the update-rocksdb-cloud-roll-guard branch from a4efc53 to d2c2aea Compare August 11, 2026 06:54
@thweetkomputer thweetkomputer changed the title chore: update rocksdb-cloud to publish file number guard on branch roll Bump rocksdb-cloud roll-guard to merged main and fix stale TTL on reused FlushRecord Aug 11, 2026
@thweetkomputer thweetkomputer changed the title Bump rocksdb-cloud roll-guard to merged main and fix stale TTL on reused FlushRecord fix: reset stale TTL on reused FlushRecord and bump rocksdb-cloud roll guard Aug 11, 2026
@thweetkomputer
thweetkomputer merged commit b04468e into main Aug 11, 2026
10 checks passed
@thweetkomputer
thweetkomputer deleted the update-rocksdb-cloud-roll-guard branch August 11, 2026 11:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants