1. 11 Aug, 2021 1 commit
  2. 04 Aug, 2021 1 commit
  3. 27 Jul, 2021 1 commit
    • Shaya Potter's avatar
      match up raft_get_last_log_term() to should_grant_vote() (#14) · fab583d6
      Shaya Potter authored
      raft_get_last_log_term() is used for filling in vote requests, except it didn't match 100% with the logic in should_grant_vote
      
      * update test to prove that change works as needed
      
      previous test tested when we don't snapshot everything, but code was broken when we did.
      modified test tested only when we snapshot everything, now we do both in sequence.
      
      * use raft_get_last_log_term in __should_grant_vote()
      
      also modify __should_grant_vote to take a raft_server_t instead of raft_server_privat_t so its not constantly casting it to void.
      fab583d6
  4. 09 Dec, 2018 1 commit
  5. 06 Dec, 2018 1 commit
  6. 07 Aug, 2018 2 commits
  7. 30 Jul, 2018 2 commits
    • Yossi Gottlieb's avatar
      Add raft_cancel_snapshot(). · 074091c1
      Yossi Gottlieb authored
      This cancels the snapshot operation and reverts back to the state we
      were in before raft_begin_snapshot().
      
      It is useful for cases where the snapshot operation fails.  It is the
      caller's responsibility to make sure the FSM state remains intact of
      course.
      074091c1
    • Yossi Gottlieb's avatar
      Add raft_cancel_snapshot(). · 3badd2a0
      Yossi Gottlieb authored
      This cancels the snapshot operation and reverts back to the state we
      were in before raft_begin_snapshot().
      
      It is useful for cases where the snapshot operation fails.  It is the
      caller's responsibility to make sure the FSM state remains intact of
      course.
      3badd2a0
  8. 20 Jun, 2018 1 commit
  9. 24 May, 2018 1 commit
  10. 08 Jan, 2018 1 commit
  11. 21 Nov, 2017 3 commits
    • Li Wei's avatar
      DAOS-333 server: Handle storage access errors · 76d56d0c
      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: default avatarLi Wei <wei.g.li@intel.com>
      76d56d0c
    • Li Wei's avatar
      DAOS-279 server: Zero timeout_elapsed for leaders · 51e049fd
      Li Wei authored
      
      
      If raft_become_candidate() assigns a negative value e (i.e.,
      -election_timeout < e < 0) to timeout_elapsed, and if this replica
      successfully becomes the leader, then this leader won't send heartbeats
      for request_timeout - e milliseconds. This may be longer than
      election_timeout and cause an unnecessary leadership change.
      
      This patch zeroes timeout_elapsed in raft_become_leader(), randomizes
      election timeouts in [election_timeout, 2 * election_timeout), and fixes
      raft_recv_appendentries() to avoid zeroing timeout_elapsed if the AE
      request has an older term.
      Signed-off-by: default avatarLi Wei <wei.g.li@intel.com>
      51e049fd
    • Li Wei's avatar
      DAOS-333 server: Persist term and vote atomically · 854a06d2
      Li Wei authored
      
      
      Remind users' persist_term implementations to persist currentTerm and
      nil votedFor atomically.
      Signed-off-by: default avatarLi Wei <wei.g.li@intel.com>
      854a06d2
  12. 09 May, 2017 1 commit
    • Willem Thiart's avatar
      Change: code now assumes callbacks are provided · c3443aac
      Willem Thiart authored
      Beforehand there were if statements to check if callbacks were provided
      by the user. This was only useful for making the test suites shorter.
      These if statements have been removed so that the core code is more
      concise.
      c3443aac
  13. 11 Jun, 2016 1 commit
  14. 13 May, 2016 2 commits
  15. 16 Mar, 2016 1 commit
  16. 25 Jan, 2016 1 commit
  17. 20 Dec, 2015 1 commit
  18. 19 Dec, 2015 3 commits
  19. 18 Nov, 2015 2 commits
  20. 13 Nov, 2015 1 commit
  21. 26 Sep, 2015 1 commit
  22. 22 Aug, 2015 1 commit
  23. 14 Aug, 2015 1 commit
  24. 07 Aug, 2015 1 commit
  25. 29 Jul, 2015 1 commit
  26. 01 May, 2015 1 commit
  27. 02 Feb, 2015 1 commit
  28. 28 May, 2014 1 commit
  29. 16 Jan, 2014 1 commit