Jun Rao created KAFKA-1390:
------------------------------

             Summary: TestUtils.waitUntilLeaderIsElectedOrChanged may wait 
longer than it needs
                 Key: KAFKA-1390
                 URL: https://issues.apache.org/jira/browse/KAFKA-1390
             Project: Kafka
          Issue Type: Improvement
    Affects Versions: 0.8.2
            Reporter: Jun Rao


The way that waitUntilLeaderIsElectedOrChanged() works is to wait for a ZK 
callback on leader change. However, if the leader is already elected (and won't 
change) at the time waitUntilLeaderIsElectedOrChanged() is called, this 
function will wait for the full timeout, which is unnecessary.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to