kafka-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jun...@apache.org
Subject [kafka] 09/09: Revert "Fix in updateBrokerInfoInZk, exception is thrown if response was not OK."
Date Fri, 02 Mar 2018 02:03:40 GMT
This is an automated email from the ASF dual-hosted git repository.

junrao pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/kafka.git

commit 57c1a687eb4a9131ddbaddd05ea9e1da0d12450d
Author: Jun Rao <junrao@gmail.com>
AuthorDate: Thu Mar 1 18:02:07 2018 -0800

    Revert "Fix in updateBrokerInfoInZk, exception is thrown if response was not OK."
    
    This reverts commit 010310388725d6393a73e12c02dff4bb85cf2518.
---
 core/src/main/scala/kafka/zk/KafkaZkClient.scala | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/core/src/main/scala/kafka/zk/KafkaZkClient.scala b/core/src/main/scala/kafka/zk/KafkaZkClient.scala
index 145e294..6545fde 100644
--- a/core/src/main/scala/kafka/zk/KafkaZkClient.scala
+++ b/core/src/main/scala/kafka/zk/KafkaZkClient.scala
@@ -88,9 +88,7 @@ class KafkaZkClient private (zooKeeperClient: ZooKeeperClient, isSecure:
Boolean
   def updateBrokerInfoInZk(brokerInfo: BrokerInfo): Unit = {
     val brokerIdPath = brokerInfo.path
     val setDataRequest = SetDataRequest(brokerIdPath, brokerInfo.toJsonBytes, ZkVersion.NoVersion)
-    val response = retryRequestUntilConnected(setDataRequest)
-     if (response.resultCode != Code.OK)
-       throw KeeperException.create(response.resultCode)
+    retryRequestUntilConnected(setDataRequest)
     info("Updated broker %d at path %s with addresses: %s".format(brokerInfo.broker.id, brokerIdPath,
brokerInfo.broker.endPoints))
   }
 

-- 
To stop receiving notification emails like this one, please contact
junrao@apache.org.

Mime
View raw message