You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ratis.apache.org by "Tsz-wo Sze (Jira)" <ji...@apache.org> on 2023/03/20 10:04:00 UTC
[jira] [Resolved] (RATIS-1817) Do not send StartLeaderElection when leaderLastEntry is null
[ https://issues.apache.org/jira/browse/RATIS-1817?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tsz-wo Sze resolved RATIS-1817.
-------------------------------
Fix Version/s: 3.0.0
Resolution: Fixed
The pull request is now merged. Thanks, [~ckj]!
> Do not send StartLeaderElection when leaderLastEntry is null
> ------------------------------------------------------------
>
> Key: RATIS-1817
> URL: https://issues.apache.org/jira/browse/RATIS-1817
> Project: Ratis
> Issue Type: Sub-task
> Components: server
> Reporter: Kaijie Chen
> Assignee: Kaijie Chen
> Priority: Minor
> Fix For: 3.0.0
>
> Time Spent: 20m
> Remaining Estimate: 0h
>
> We should not send StartLeaderElection to the transferee when {{leaderLastEntry}} is null.
> Because {{leaderLastEntry}} is expected to be non-null inĀ {{RaftServerImpl#startLeaderElection}}:
> {code:java}
> if (leaderLastEntry == null) {
> LOG.warn("{}: receive null leaderLastEntry which is unexpected", getMemberId());
> return ServerProtoUtils.toStartLeaderElectionReplyProto(leaderId, getMemberId(), false);
> }
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)