C0urante opened a new pull request #10014: URL: https://github.com/apache/kafka/pull/10014
Address [KAFKA-12252](https://issues.apache.org/jira/browse/KAFKA-12252) and [KAFKA-12262](https://issues.apache.org/jira/browse/KAFKA-12262). - To address `KAFKA-12262`, all workers now track key expiration instead of just the leader. - To address `KAFKA-12252`, a conditional check is added in the herder tick thread to only cut rebalance polling short for key rotation if the worker is the leader. Unit tests for the distributed herder are added for both bugs. The first ensures that if a worker becomes the leader after reading a session key from the config topic, it wakes up from polling for rebalance in time for key rotation. The second ensures that if a worker loses leadership, it stops taking key expiration into account when calculating the time to poll for rebalance. ### Committer Checklist (excluded from commit message) - [ ] Verify design and implementation - [ ] Verify test coverage and CI build status - [ ] Verify documentation (including upgrade notes) ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org