diff --git a/deps/rabbit/src/rabbit_khepri.erl b/deps/rabbit/src/rabbit_khepri.erl index 5f7cfb17385..728430e48c3 100644 --- a/deps/rabbit/src/rabbit_khepri.erl +++ b/deps/rabbit/src/rabbit_khepri.erl @@ -375,7 +375,7 @@ remove_reachable_member(NodeToRemove) -> remove_down_member(NodeToRemove) -> ServerRef = khepri_cluster:node_to_member(?STORE_ID, node()), ServerId = khepri_cluster:node_to_member(?STORE_ID, NodeToRemove), - Timeout = khepri:get_default_timeout(), + Timeout = khepri_app:get_default_timeout(), Ret = ra:remove_member(ServerRef, ServerId, Timeout), case Ret of {ok, _, _} -> @@ -461,8 +461,8 @@ transfer_leadership0([Destination | TransferCandidates]) -> rabbit_log:info("Khepri clustering: transferring leadership to node ~p", [Destination]), case ra_leaderboard:lookup_leader(?STORE_ID) of {Name, Node} = Id when Node == node() -> - Timeout = khepri:get_default_timeout(), - case ra:transfer_leadership(Id, {Name, Destination}, Timeout) of + Timeout = khepri_app:get_default_timeout(), + case ra:transfer_leadership(Id, {Name, Destination}) of ok -> case ra:members(Id, Timeout) of {_, _, {_, NewNode}} ->