C0urante opened a new pull request, #16788:
URL: https://github.com/apache/kafka/pull/16788

   [Jira](https://issues.apache.org/jira/browse/KAFKA-17252)
   
   With the current session key tracking logic on trunk, there's a small chance 
that a herder may not updated its [sessionKey 
field](https://github.com/apache/kafka/blob/8438c4339e0a103d95575336a9f3653698cd0b8e/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/distributed/DistributedHerder.java#L219)
 to contain a session key, even if a key is present in the topic and has been 
read by the `KafkaConfigBackingStore`'s work thread.
   
   This is because the backing store does not notify its listener of new 
records consumed from the config topic while it is starting up, which for most 
record types (connector configs, target states, restart requests, etc.) is 
perfectly valid. However, for session keys, it's fine to notify the herder, 
since the only thing that it does is [update a few 
fields](https://github.com/apache/kafka/blob/8438c4339e0a103d95575336a9f3653698cd0b8e/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/distributed/DistributedHerder.java#L2508-L2522).
   
   This should hopefully address some flaky test failures we've seen for the 
`DedicatedMirrorIntegrationTest::testMultiNodeCluster` case, like the one 
[here](https://ge.apache.org/starting/s/52il7msnknzp2/tests/task/:connect:mirror:test/details/org.apache.kafka.connect.mirror.integration.DedicatedMirrorIntegrationTest/testMultiNodeCluster()?top-execution=1).
   
   ### 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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to