You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by ma...@apache.org on 2023/02/07 18:35:28 UTC

[kafka] 01/02: MINOR: Add FeatureZNode ZK node path to ZK root paths

This is an automated email from the ASF dual-hosted git repository.

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

commit 8cdf9564ab0f56845bb0cc0192a43b39c26c3375
Author: Manikumar Reddy <ma...@gmail.com>
AuthorDate: Mon Feb 6 17:59:22 2023 +0530

    MINOR: Add FeatureZNode ZK node path to ZK root paths
---
 core/src/main/scala/kafka/zk/ZkData.scala                              | 3 ++-
 core/src/test/scala/unit/kafka/security/auth/ZkAuthorizationTest.scala | 2 ++
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/core/src/main/scala/kafka/zk/ZkData.scala b/core/src/main/scala/kafka/zk/ZkData.scala
index cc48c46ef72..15457ac009a 100644
--- a/core/src/main/scala/kafka/zk/ZkData.scala
+++ b/core/src/main/scala/kafka/zk/ZkData.scala
@@ -1088,7 +1088,8 @@ object ZkData {
     LogDirEventNotificationZNode.path,
     DelegationTokenAuthZNode.path,
     ExtendedAclZNode.path,
-    MigrationZNode.path) ++ ZkAclStore.securePaths
+    MigrationZNode.path,
+    FeatureZNode.path) ++ ZkAclStore.securePaths
 
   // These are persistent ZK paths that should exist on kafka broker startup.
   val PersistentZkPaths = Seq(
diff --git a/core/src/test/scala/unit/kafka/security/auth/ZkAuthorizationTest.scala b/core/src/test/scala/unit/kafka/security/auth/ZkAuthorizationTest.scala
index 3c35fd7d429..aab892b3346 100644
--- a/core/src/test/scala/unit/kafka/security/auth/ZkAuthorizationTest.scala
+++ b/core/src/test/scala/unit/kafka/security/auth/ZkAuthorizationTest.scala
@@ -255,6 +255,8 @@ class ZkAuthorizationTest extends QuorumTestHarness with Logging {
     assertTrue(isAclCorrect(consumersAcl, false, false), ConsumerPathZNode.path)
     assertTrue(isAclCorrect(firstZk.getAcl("/kafka-acl-extended"), secondZk.secure,
       ZkData.sensitivePath(ExtendedAclZNode.path)), "/kafka-acl-extended")
+    assertTrue(isAclCorrect(firstZk.getAcl("/feature"), secondZk.secure,
+      ZkData.sensitivePath(FeatureZNode.path)), "ACL mismatch for /feature path")
   }
 
   /**