[
https://issues.apache.org/jira/browse/RATIS-1817?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17702537#comment-17702537
]
Kaijie Chen commented on RATIS-1817:
------------------------------------
[~szetszwo] seems leaderLastEntry is a must for StartLeaderElection (as
discussed in RATIS-1818), please take a look at this change.
> 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
> Reporter: Kaijie Chen
> Assignee: Kaijie Chen
> Priority: Minor
> Time Spent: 10m
> 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)