Skip to content

Commit

Permalink
Merge pull request #18039 from vbotbuildovich/backport-pr-18021-v23.3…
Browse files Browse the repository at this point in the history
….x-570

[v23.3.x] c/controller_backend: try to force-abort reconfiguration only on leaders
  • Loading branch information
ztlpn authored Apr 24, 2024
2 parents 22d869b + 031e6fd commit 8becb6a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/v/cluster/controller_backend.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1685,6 +1685,14 @@ controller_backend::force_abort_replica_set_update(
}
co_return errc::waiting_for_recovery;
} else {
auto leader_id = partition->get_leader_id();
if (leader_id && leader_id != _self) {
// The leader is alive and we are a follower. Wait for the leader to
// replicate the aborting configuration, but don't append it
// ourselves to minimize the chance of log inconsistency.
co_return errc::not_leader;
}

vlog(
clusterlog.debug,
"[{}] force-aborting reconfiguration",
Expand Down

0 comments on commit 8becb6a

Please sign in to comment.