Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-3045

ZkNodeChangeNotificationListener shouldn't log interrupted exception as error

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.9.0.0
    • Fix Version/s: 0.9.0.1
    • Component/s: core
    • Labels:

      Description

      Saw the following when running /opt/kafka/bin/kafka-acls.sh --authorizer kafka.security.auth.SimpleAclAuthorizer.

      [2015-12-28 08:04:39,382] ERROR Error processing notification change for path = /kafka-acl-changes and notification= [acl_changes_0000000004, acl_changes_0000000003, acl_changes_0000000002, acl_changes_0000000001, acl_changes_0000000000] : (kafka.common.ZkNodeChangeNotificationListener)

      org.I0Itec.zkclient.exception.ZkInterruptedException: java.lang.InterruptedException

      at org.I0Itec.zkclient.ZkClient.retryUntilConnected(ZkClient.java:997)

      at org.I0Itec.zkclient.ZkClient.readData(ZkClient.java:1090)

      at org.I0Itec.zkclient.ZkClient.readData(ZkClient.java:1085)

      at kafka.utils.ZkUtils.readDataMaybeNull(ZkUtils.scala:525)

      at kafka.security.auth.SimpleAclAuthorizer.kafka$security$auth$SimpleAclAuthorizer$$getAclsFromZk(SimpleAclAuthorizer.scala:213)

      at kafka.security.auth.SimpleAclAuthorizer$AclChangedNotificaitonHandler$.processNotification(SimpleAclAuthorizer.scala:273)

      at kafka.common.ZkNodeChangeNotificationListener$$anonfun$kafka$common$ZkNodeChangeNotificationListener$$processNotifications$2$$anonfun$apply$2.apply(ZkNodeChangeNotificationListener.scala:84)

      at kafka.common.ZkNodeChangeNotificationListener$$anonfun$kafka$common$ZkNodeChangeNotificationListener$$processNotifications$2$$anonfun$apply$2.apply(ZkNodeChangeNotificationListener.scala:84)

      at scala.Option.map(Option.scala:146)

      at kafka.common.ZkNodeChangeNotificationListener$$anonfun$kafka$common$ZkNodeChangeNotificationListener$$processNotifications$2.apply(ZkNodeChangeNotificationListener.scala:84)

      at kafka.common.ZkNodeChangeNotificationListener$$anonfun$kafka$common$ZkNodeChangeNotificationListener$$processNotifications$2.apply(ZkNodeChangeNotificationListener.scala:79)

      at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59)

      at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:48)

      at kafka.common.ZkNodeChangeNotificationListener.kafka$common$ZkNodeChangeNotificationListener$$processNotifications(ZkNodeChangeNotificationListener.scala:79)

      at kafka.common.ZkNodeChangeNotificationListener$NodeChangeListener$.handleChildChange(ZkNodeChangeNotificationListener.scala:121)

      at org.I0Itec.zkclient.ZkClient$10.run(ZkClient.java:842)

      at org.I0Itec.zkclient.ZkEventThread.run(ZkEventThread.java:71)

      Caused by: java.lang.InterruptedException

      at java.lang.Object.wait(Native Method)

      at java.lang.Object.wait(Object.java:502)

      at org.apache.zookeeper.ClientCnxn.submitRequest(ClientCnxn.java:1342)

      at org.apache.zookeeper.ZooKeeper.getData(ZooKeeper.java:1153)

      at org.apache.zookeeper.ZooKeeper.getData(ZooKeeper.java:1184)

      at org.I0Itec.zkclient.ZkConnection.readData(ZkConnection.java:119)

      at org.I0Itec.zkclient.ZkClient$12.call(ZkClient.java:1094)

      at org.I0Itec.zkclient.ZkClient$12.call(ZkClient.java:1090)

      at org.I0Itec.zkclient.ZkClient.retryUntilConnected(ZkClient.java:985)

      When SimpleAclAuthorizer terminates, we close zkclient, which interrupts the watcher processor thread. Since this is expected, we shouldn't log this as an error.

        Attachments

          Activity

            People

            • Assignee:
              lindong Dong Lin
              Reporter:
              junrao Jun Rao
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: