-
Notifications
You must be signed in to change notification settings - Fork 845
refactor(meta): upgrade openraft to v0.10.0-alpha.13 #19193
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5954c64f79
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
3372b48 to
086bd0d
Compare
xp-trumpet
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xp-trumpet reviewed 18 files and all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @drmingdrmer).
drmingdrmer
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@drmingdrmer resolved 1 discussion.
Reviewable status: 6 of 18 files reviewed, all discussions resolved (waiting on @xp-trumpet).
76e12cc to
5ec5af0
Compare
…ized payloads Upgrade openraft dependency and adapt to API changes in the new version. The main changes include a new streaming apply API, updated watch receiver trait methods, and automatic payload size management for AppendEntries. In openraft 0.10.0, `PayloadTooLarge` error was removed. This change implements automatic payload size management in `append_entries()` by reducing entry count and retrying when payloads exceed gRPC limits. Changes: - Upgrade openraft from `v0.10.0-alpha.11` to `v0.10.0-alpha.13` - Update `TypeConfig` to use new `Responder<T>` and `ErrorSource` types - Add type aliases: `WatchReceiver<T>`, `Unreachable`, `EntryResponder` - Change `SMV003::apply_entries()` to accept stream instead of iterator - Replace `.borrow()` with `.borrow_watched()` for watch receivers - Add `From<SnapshotStoreError> for io::Error` implementation - Update tests to use stream-based apply API - Add retry loop in `append_entries()` to handle oversized payloads - Add `build_partial_append_request()` helper for creating partial requests - Check payload size before sending against `advisory_encoding_size()` - Handle `tonic::Code::ResourceExhausted` by reducing entries and retrying - Return `Unreachable` error when single entry exceeds size limit - Remove obsolete `new_append_entries_raft_req()` function
I hereby agree to the terms of the CLA available at: https://docs.databend.com/dev/policies/cla/
Summary
refactor(meta): upgrade openraft to v0.10.0-alpha.13
Upgrade openraft dependency and adapt to API changes in the new version.
The main changes include a new streaming apply API and updated watch
receiver trait methods.
Changes:
v0.10.0-alpha.11tov0.10.0-alpha.13TypeConfigto use newResponder<T>andErrorSourcetypesWatchReceiver<T>,Unreachable,EntryResponderSMV003::apply_entries()to accept stream instead of iterator.borrow()with.borrow_watched()for watch receiversFrom<SnapshotStoreError> for io::ErrorimplementationTests
Type of change
Related Issues
This change is