unify cluster db store import error handling#55
Merged
Conversation
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.
Summary
import_*methods now propagateSerializationErroron deserialize failure. PreviouslyIndexStore::import_entriespropagated via?whileDbDataStore,SchemaStore,ConstraintStore,UniqueStore, andFkValidationStoresilently skipped malformed entries — a corrupt snapshot stream would either truncate or abort depending on which store hit the bad bytes first.IndexStore::import_entriescounter accuracy. It used to incrementimportedeven whenadd_entryreturnedErr(AlreadyExists), inflating the count on idempotent snapshot replay. Now only successful inserts are counted;AlreadyExistsis treated as benign replay (so a second import of the same payload returnsOk(0)), and any other error variant propagates.# Errorsdocstrings on all six methods to accurately reflect the failure modes (UTF-8 key parse failure and entity deserialize failure).import_entries_is_idempotent_on_replayinindex_store.rscovers the counter fix.mqdb-cluster0.3.2 → 0.3.3, CHANGELOG entry under2026-05-03.Test plan
cargo test -p mqdb-cluster --lib— 466 passed (465 prior + 1 new test)cargo make clippy— clean (pedantic, all targets + wasm)cargo make format-check— cleancargo make dev— full workspace passes