Skip to content
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

give a chance for the last obj to retry #547

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions include/libnuraft/state_machine.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -200,13 +200,20 @@ public:
* this parameter.
* @param data Payload of given object.
* @param is_first_obj `true` if this is the first object.
* @param is_last_obj `true` if this is the last object.
* @param is_last_obj[in,out]
* when [in]
* `true` if this is the last object indicated by the sender.
*
* when [out]
* As a result of this API call, if the receiver wants the sender
* to resend the last object, it should set this parameter to `false`,
* so that apply_snapshot() will not be called.
*/
virtual void save_logical_snp_obj(snapshot& s,
ulong& obj_id,
buffer& data,
bool is_first_obj,
bool is_last_obj) {}
bool& is_last_obj) {}

/**
* Apply received snapshot to state machine.
Expand Down
Loading