-
Notifications
You must be signed in to change notification settings - Fork 164
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feature:
RaftNetwork::send_append_entries()
can return PartialSuccess
If there are too many log entries and the `RPCOption.ttl` is not sufficient, an application can opt to only send a portion of the entries, with `AppendEntriesResponse::PartialSuccess(Option<LogId>)`, to inform Openraft with the last replicated log id. Thus replication can still make progress. For example, it tries to send log entries `[1-2..3-10]`, the application is allowed to send just `[1-2..1-3]` and return `PartialSuccess(1-3)`, ### Caution The returned matching log id must be **greater than or equal to** the first log id(`AppendEntriesRequest::prev_log_id`) of the entries to send. If no RPC reply is received, `RaftNetwork::send_append_entries` **must** return an `RPCError` to inform Openraft that the first log id(`AppendEntriesRequest::prev_log_id`) may not match on the remote target node. - Fix: #822
- Loading branch information
1 parent
5583e53
commit 1ee82cb
Showing
11 changed files
with
355 additions
and
89 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.