Luke Chen created KAFKA-14280: --------------------------------- Summary: quorum election random backoff always return 0 for 1st timeout 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
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 we 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)