You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have confirmed that this bug belongs to the current repository, not other repositories of RocketMQ.
Runtime platform environment
macos 12.6.3
RocketMQ version
develop branch
JDK Version
No response
Describe the Bug
When controllerMode is true, inactive brokers and brokers that need to be elected will be checked regularly (the code is in RaftBrokerHeartBeatManager#scanNotActiveBroker). But the logic to determine whether a broker needs to be elected is incorrect. The consequence is that unexpected elections occur when follow broker is inactive and master broker is active.
Steps to Reproduce
stop a follow broker
What Did You Expect to See?
master broker active and follow broker inactive, no election
What Did You See Instead?
an election took place
Additional Context
No response
The text was updated successfully, but these errors were encountered:
Before Creating the Bug Report
I found a bug, not just asking a question, which should be created in GitHub Discussions.
I have searched the GitHub Issues and GitHub Discussions of this repository and believe that this is not a duplicate.
I have confirmed that this bug belongs to the current repository, not other repositories of RocketMQ.
Runtime platform environment
macos 12.6.3
RocketMQ version
develop branch
JDK Version
No response
Describe the Bug
When controllerMode is true, inactive brokers and brokers that need to be elected will be checked regularly (the code is in RaftBrokerHeartBeatManager#scanNotActiveBroker). But the logic to determine whether a broker needs to be elected is incorrect. The consequence is that unexpected elections occur when follow broker is inactive and master broker is active.
![image](https://cdn.statically.io/img/private-user-images.githubusercontent.com/65004897/346597055-61a901f0-af87-4f2f-afc8-b79c9a3ccbca.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjE5OTAwMzIsIm5iZiI6MTcyMTk4OTczMiwicGF0aCI6Ii82NTAwNDg5Ny8zNDY1OTcwNTUtNjFhOTAxZjAtYWY4Ny00ZjJmLWFmYzgtYjc5YzlhM2NjYmNhLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50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kSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.r18vCUvO1ZdDZ6mFWGXOwbgVPkcuXRiIEzAdCZdrGdI)
![image](https://cdn.statically.io/img/private-user-images.githubusercontent.com/65004897/346602171-04ff4349-ed9f-4299-860f-680404482ccc.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjE5OTAwMzIsIm5iZiI6MTcyMTk4OTczMiwicGF0aCI6Ii82NTAwNDg5Ny8zNDY2MDIxNzEtMDRmZjQzNDktZWQ5Zi00Mjk5LTg2MGYtNjgwNDA0NDgyY2NjLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MjYlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzI2VDEwMjg1MlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTI1Y2ZiZDhjMDUwMGRkMjgyNWM1YzRkZDJhYzMwZmU2OGRmZTY3NWZlYTk3ODNkMmYzZmE3ZDk0ZDJkNDkyNzgmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.OIwmRQ1CnFotWJx2v4Fu4jC0KcMx2D1GuSo6m1TdsZI)
Steps to Reproduce
stop a follow broker
What Did You Expect to See?
master broker active and follow broker inactive, no election
What Did You See Instead?
an election took place
Additional Context
No response
The text was updated successfully, but these errors were encountered: