Xinyu Tan created RATIS-2138:
--------------------------------

             Summary: Remove uncessary error log in JVMPauseMonitor When GC is 
serious
                 Key: RATIS-2138
                 URL: https://issues.apache.org/jira/browse/RATIS-2138
             Project: Ratis
          Issue Type: Improvement
            Reporter: Xinyu Tan
            Assignee: Xinyu Tan
         Attachments: image-2024-08-12-14-13-05-825.png, 
image-2024-08-12-14-14-45-615.png, image-2024-08-12-14-17-13-030.png

JVMPauseMonitor may be printing unexpected Error logs when GC is heavy and the 
cluster keeps triggering re-election. 
!image-2024-08-12-14-13-05-825.png! 

After investigating the relevant code, it is found that the Preconditions here 
are unreasonable. When we update, we will first update the serverstate's term 
and then shutdown LeaderState. If any other thread calls leaderState's 
getCurrentTerm in the meantime, this will cause an error, so it's not necessary 
at this point

 !image-2024-08-12-14-14-45-615.png! 
 !image-2024-08-12-14-17-13-030.png! 





--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to