You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "Luke Chen (Jira)" <ji...@apache.org> on 2022/10/16 12:06:00 UTC
[jira] [Resolved] (KAFKA-14280) quorum election random backoff always return 0 for 1st retry
[ https://issues.apache.org/jira/browse/KAFKA-14280?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Luke Chen resolved KAFKA-14280.
-------------------------------
Resolution: Not A Problem
Closed as not a problem
> quorum election random backoff always return 0 for 1st retry
> ------------------------------------------------------------
>
> Key: KAFKA-14280
> URL: https://issues.apache.org/jira/browse/KAFKA-14280
> Project: Kafka
> Issue Type: Bug
> Components: kraft
> Affects Versions: 3.3.1
> Reporter: Luke Chen
> Assignee: Luke Chen
> Priority: Major
>
> When doing quorum election, we added a random election backoff if vote got rejected or timeout, and hope next round, there will be no conflict between different voters. But currently, we calculate the random backoff by:
>
> {code:java}
> Math.min(RETRY_BACKOFF_BASE_MS * random.nextInt(2 << Math.min(20, retries - 1)),
> raftConfig.electionBackoffMaxMs());{code}
>
> That means, when multiple candidates tried to backoff for the 1st retries, they will all get 0ms backoff, and then keep conflicting again.
>
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)