feat(streaming): implement checkpoint coordination with catalog-backed crash recovery#223
Open
luoluoyuyu wants to merge 5 commits intoFunctionStream:mainfrom
Open
feat(streaming): implement checkpoint coordination with catalog-backed crash recovery#223luoluoyuyu wants to merge 5 commits intoFunctionStream:mainfrom
luoluoyuyu wants to merge 5 commits intoFunctionStream:mainfrom
Conversation
…d crash recovery Introduce a full Chandy-Lamport distributed snapshot mechanism with catalog-persisted safe epochs for exactly-once crash recovery: - Add LSM-Tree state engine with MVCC, Bloom filters, watermark GC, dedicated I/O thread pool with panic isolation (state/ module) - Add JobMasterEvent protocol for checkpoint ACK/Decline signaling - Integrate MemoryController and IoPool into JobManager lifecycle - Implement checkpoint coordinator: periodic barrier injection, ACK collection, and CatalogManager.commit_job_checkpoint() callback - Extend StreamingTableDefinition proto with checkpoint_interval_ms and latest_checkpoint_epoch for durable recovery metadata - Support user-defined checkpoint interval via SQL WITH clause - Restore streaming jobs from catalog with precise epoch recovery Made-with: Cursor
…e watermark harvesting - Extend TaskContext with state_dir, memory_controller, io_manager, and safe_epoch to bridge operators with the state engine - Refactor JoinWithExpirationOperator: replace in-memory VecDeque with PersistentStateBuffer backed by OperatorStateStore, using composite keys [Side(1B) + Timestamp(8B BE)] and BTreeSet timeline index - Refactor InstantJoinOperator: replace in-memory BTreeMap<SystemTime, JoinInstance> with LSM-Tree persistence, split process_watermark into 3-phase pipeline (harvest -> compute -> cleanup) to eliminate interleaved mutable/immutable borrow conflicts - Both operators now support on_start recovery via restore_metadata and snapshot_state via snapshot_epoch for exactly-once semantics Made-with: Cursor
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.
No description provided.