feat(storage): BlobRedundancyManager — implement RocksDB EventListener for SST deletion#4201
Open
feat(storage): BlobRedundancyManager — implement RocksDB EventListener for SST deletion#4201
Conversation
…deletion events - Fix createRocksDBListener() to return a real RocksDBBlobListener instead of an error - Add BlobRedundancyManager::notifySSTFileDeleted() to mark locations unhealthy and queue repair - Implement RocksDBBlobListener::OnTableFileDeleted() delegating to notifySSTFileDeleted() - Add RocksDBWrapper::addEventListener() to register listeners before DB open - Add 5 BlobRedundancyManagerTest cases covering listener creation and SST deletion handling - Add test_blob_redundancy_event_listener_focused CMake target - Add blob-redundancy-event-listener-ci.yml CI workflow Co-authored-by: makr-code <150588092+makr-code@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Implement RocksDB event listener in BlobRedundancyManager
feat(storage): BlobRedundancyManager — implement RocksDB EventListener for SST deletion
Mar 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
createRocksDBListener()unconditionally returned"RocksDB listener not implemented"andOnTableFileDeleted()was a no-op, leaving the redundancy manager blind to compaction-driven SST deletions and unable to trigger replication for blobs that lost their backing file.Changes
Core implementation
createRocksDBListener(): returns a realRocksDBBlobListenerinstead of an errornotifySSTFileDeleted(file_path)(new public method): write-locksblobs_, marks everyBlobLocationwhosepathmatches asis_healthy = false, collects affected blob IDs, and drains them intorepair_queue_withrepair_cv_.notify_all()RocksDBBlobListener::OnTableFileDeleted(): delegates tonotifySSTFileDeleted(info.file_path)— was previously a logging stubListener registration
RocksDBWrapper::addEventListener(shared_ptr<EventListener>)(new): pushes intooptions_->listenersbeforeopen()so callers can wire the blob listener at DB-open time#include <rocksdb/listener.h>andclass EventListenerforward-declaration torocksdb_wrapperTests (
tests/test_raid_redundancy.cpp)CreateRocksDBListenerSucceeds— factory returns non-nullNotifySSTFileDeletedMarksLocationUnhealthy— primary location transitions to unhealthyNotifySSTFileDeletedUnknownPathIsNoOp— unknown path does not crash or mutate stateNotifySSTFileDeletedOnlyAffectsMatchingBlobs— sibling blob stays healthyRocksDBListenerOnTableFileDeletedTriggersReplication— end-to-end:OnTableFileDeletedvia factory listener marks location unhealthyBuild / CI
tests/CMakeLists.txt:test_blob_redundancy_event_listener_focusedtarget runningBlobRedundancyManagerTest.*.github/workflows/blob-redundancy-event-listener-ci.yml: matrix (gcc-12, clang-15, gcc-13) scoped to the touched filesType of Change
Testing
📚 Research & Knowledge (wenn applicable)
/docs/research/angelegt?/docs/research/implementation_influence/eingetragen?Relevante Quellen:
Checklist
Original prompt
BlobRedundancyManager: Implement RocksDB Event Listener #4089📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.