[
https://issues.apache.org/jira/browse/RATIS-2172?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Tsz-wo Sze resolved RATIS-2172.
-------------------------------
Fix Version/s: 3.2.0
Resolution: Fixed
The pull request is now merged. Thanks, [~tohsakarin__]!
> RaftServer may lose FollowerState
> ---------------------------------
>
> Key: RATIS-2172
> URL: https://issues.apache.org/jira/browse/RATIS-2172
> Project: Ratis
> Issue Type: Bug
> Components: server
> Affects Versions: 3.1.1
> Reporter: yuuka
> Assignee: yuuka
> Priority: Critical
> Fix For: 3.2.0
>
> Attachments: image-2024-10-10-11-12-33-251.png,
> image-2024-10-10-11-13-13-540.png, image-2024-10-10-11-13-43-436.png
>
> Time Spent: 2h 20m
> Remaining Estimate: 0h
>
> When RaftServer starts, startComplete.compareAndSet(false, true) may occur
> after LeaderElection, in which case FollowerState may be lost
>
> 1. Start the FollowerState thread, then Follower becomes candidate before
> *startComplete* is set to true
> !image-2024-10-10-11-12-33-251.png!
> 2. Due to startComplete is false currently, so this leaderElection will ending
>
> !image-2024-10-10-11-13-13-540.png!
> 3. Then the FollowerState thread will exit, causing the raftServer to lose
> role information
> !image-2024-10-10-11-13-43-436.png!
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)