- 16 Oct, 2018 1 commit
-
-
Yossi Gottlieb authored
This is probably most common when loading a snapshot. Currently it is only possibly to free allocated entry memory on log_pop and log_poll, but neither are called on log_reset(). This is a quick and non-breaking fix. A better but not backward compatible option can be to have a free function callback as part of the entry itself (automatically called when needed, not by log_pop or log_poll). This would also make it easier to avoid redundant buffer allocs/copies on the app side.
-
- 20 Jun, 2018 2 commits
-
-
Yossi Gottlieb authored
-
Yossi Gottlieb authored
-
- 07 Jun, 2018 2 commits
-
-
Willem Thiart authored
The RAFT_LOGTYPE_SNAPSHOT was a bad design choice. It's better to not have this marker entry so that users don't have to check for the log entry type in the callbacks. Also, loading a snapshot correctly created this marker entry, but the compaction side did not. It's better to remove this log type than to fix this asymmetry. Fixes the following edge cases: - Server crashes if the last snapshot index is N and a appendentries message pops entries all the way back to index N. - Server sends an appendentries message with an invalid prev_log_idx and prev_log_term, causing the peer to crash.
-
Yossi Gottlieb authored
* Fix off-by-one in apply_log idx. * Fix log_get_from_idx() off by one error.
-
- 17 May, 2018 1 commit
-
-
Li Wei authored
Since mod() has a short name and is only in raft_log.c, it should be static. Signed-off-by:
Li Wei <wei.g.li@intel.com>
-
- 16 May, 2018 1 commit
-
-
Yossi Gottlieb authored
-
- 08 Jan, 2018 1 commit
-
-
Willem Thiart authored
-
- 29 Dec, 2017 1 commit
-
-
Willem Thiart authored
The raft_log API is now being fuzzed tested. This change fixes all of the bugs detected by the fuzzer so far.
-
- 21 Nov, 2017 4 commits
-
-
Li Wei authored
User storage callbacks may return negative errors smaller than RAFT_ERR_LAST. These will be returned all the way to the API methods, which report the errors back to users, so that appropriate handlings may be performed. Signed-off-by:
Li Wei <wei.g.li@intel.com>
-
Li Wei authored
log_offer and log_poll should get log entry index rather than internal array index. That would match the callback comment in raft.h and would also match the log_pop case. Signed-off-by:
Li Wei <wei.g.li@intel.com>
-
Li Wei authored
Check and handle memory allocation errors by reporting them back to users via NULL or RAFT_ERR_NOMEM return values. Signed-off-by:
Li Wei <wei.g.li@intel.com>
-
Li Wei authored
log_append_entry() passes caller's raft_entry_t to log_offer. If the log_offer implementation sets the data buffer to different value, caller's raft_entry_t gets modified as a side effect. This is error-prone as callers are usually responsible for freeing the data buffer with such a log_offer implementation. This patch passes the raft_entry_t in the log to log_offer instead. Also, ety in raft_recv_entry() is no longer required. Signed-off-by:
Li Wei <wei.g.li@intel.com>
-
- 11 Jun, 2016 1 commit
-
-
Willem Thiart authored
-
- 22 May, 2016 1 commit
-
-
Willem Thiart authored
-
- 11 Apr, 2016 2 commits
-
-
Willem Thiart authored
Regression caused by 6f318d01
-
Willem Thiart authored
Regression caused by d106d229
-
- 16 Mar, 2016 3 commits
-
-
Willem Thiart authored
This change is backwards incompatible. The following functions return different return codes: * applylog * log_offer * raft_append_entry * raft_apply_all * raft_recv_entry
-
Willem Thiart authored
-
Willem Thiart authored
-
- 11 Feb, 2016 1 commit
-
-
Willem Thiart authored
-
- 01 Feb, 2016 1 commit
-
-
Willem Thiart authored
A regression caused by a20e8592.
-
- 29 Jan, 2016 1 commit
-
-
Willem Thiart authored
-
- 28 Jan, 2016 1 commit
-
-
Willem Thiart authored
Performance improvement. Appendentries will now send many logs per message.
-
- 04 Nov, 2015 1 commit
-
-
Willem Thiart authored
Thanks to @ar104 for the fix!
-
- 15 Oct, 2015 1 commit
-
-
Willem Thiart authored
-
- 01 Oct, 2015 1 commit
-
-
Willem Thiart authored
-
- 22 Aug, 2015 1 commit
-
-
Willem Thiart authored
-
- 15 Aug, 2015 1 commit
-
-
Willem Thiart authored
-
- 14 Aug, 2015 1 commit
-
-
Willem Thiart authored
-
- 04 Aug, 2015 1 commit
-
-
Willem Thiart authored
-
- 01 May, 2015 1 commit
-
-
Alex Fabijanic authored
-
- 21 Feb, 2015 1 commit
-
-
Willem Thiart authored
-
- 02 Feb, 2015 2 commits
-
-
Willem Thiart authored
-
Willem Thiart authored
-
- 01 Feb, 2015 1 commit
-
-
Willem Thiart authored
-
- 28 May, 2014 1 commit
-
-
Willem Thiart authored
-
- 26 Feb, 2014 1 commit
-
-
willem authored
-
- 16 Jan, 2014 1 commit
-
-
willem authored
-
- 13 Jan, 2014 1 commit
-
-
willem authored
-