Skip to content

Commit

Permalink
Define is_proposer by comparing m_raft_server_id with rkey.server_id
Browse files Browse the repository at this point in the history
  • Loading branch information
yawzhang committed Dec 23, 2024
1 parent c388f69 commit 94bf6b9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 11 deletions.
3 changes: 1 addition & 2 deletions conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@

class HomestoreConan(ConanFile):
name = "homestore"
version = "6.6.1"

version = "6.6.2"
homepage = "https://github.com/eBay/Homestore"
description = "HomeStore Storage Engine"
topics = ("ebay", "nublox")
Expand Down
12 changes: 3 additions & 9 deletions src/lib/replication/repl_dev/raft_state_machine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,15 +154,9 @@ repl_req_ptr_t RaftStateMachine::localize_journal_entry_finish(nuraft::log_entry

auto rreq = m_rd.repl_key_to_req(rkey);
if ((rreq == nullptr) || (rreq->is_localize_pending())) {
rreq = localize_journal_entry_prepare(lentry);
if (rreq == nullptr) {
RELEASE_ASSERT(rreq != nullptr,
"We get an linked data for rkey=[{}], jentry=[{}] not as part of Raft Append but "
"indirectly through possibly unpack() and in those cases, if we are not able to alloc "
"location to write the data, there is no recourse. So we must crash this system ",
rkey.to_string(), jentry->to_string());
return nullptr;
}
// This path is for log pack apply only.
// Now we fully disabled log pack/unpack with the new_learner opt, should not reaching here.
RELEASE_ASSERT(false, "rreq should have already localized for rkey=[{}]", rkey.to_string());
}

if (rreq->is_proposer()) {
Expand Down

0 comments on commit 94bf6b9

Please sign in to comment.