kafka-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rha...@apache.org
Subject [kafka] branch 2.3 updated: KAFKA-8265: Fix config name to match KIP-458. (#6755)
Date Wed, 22 May 2019 00:36:27 GMT
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/2.3 by this push:
     new 9dfdc58  KAFKA-8265: Fix config name to match KIP-458. (#6755)
9dfdc58 is described below

commit 9dfdc584519e3ffb9d10fba33a994eeea9c4e2d0
Author: Magesh Nandakumar <magesh.n.kumar@gmail.com>
AuthorDate: Mon May 20 12:02:22 2019 -0700

    KAFKA-8265: Fix config name to match KIP-458. (#6755)
    
    Return a copy of the ConfigDef in Client Configs. Related to KIP-458.
    
    Author: Magesh Nandakumar <magesh.n.kumar@gmail.com
    Reviewer: Randall Hauch <rhauch@gmail.com>
---
 .../src/main/java/org/apache/kafka/clients/admin/AdminClientConfig.java | 2 +-
 .../src/main/java/org/apache/kafka/clients/consumer/ConsumerConfig.java | 2 +-
 .../src/main/java/org/apache/kafka/clients/producer/ProducerConfig.java | 2 +-
 .../connector/policy/AllConnectorClientConfigOverridePolicy.java        | 2 +-
 .../connector/policy/NoneConnectorClientConfigOverridePolicy.java       | 2 +-
 .../connector/policy/PrincipalConnectorClientConfigOverridePolicy.java  | 2 +-
 .../src/main/java/org/apache/kafka/connect/runtime/WorkerConfig.java    | 2 +-
 7 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/clients/src/main/java/org/apache/kafka/clients/admin/AdminClientConfig.java b/clients/src/main/java/org/apache/kafka/clients/admin/AdminClientConfig.java
index 1fa2335..ba97b5b 100644
--- a/clients/src/main/java/org/apache/kafka/clients/admin/AdminClientConfig.java
+++ b/clients/src/main/java/org/apache/kafka/clients/admin/AdminClientConfig.java
@@ -201,7 +201,7 @@ public class AdminClientConfig extends AbstractConfig {
     }
 
     public static ConfigDef configDef() {
-        return  CONFIG;
+        return  new ConfigDef(CONFIG);
     }
 
     public static void main(String[] args) {
diff --git a/clients/src/main/java/org/apache/kafka/clients/consumer/ConsumerConfig.java b/clients/src/main/java/org/apache/kafka/clients/consumer/ConsumerConfig.java
index c80b71f..ff2e5cd 100644
--- a/clients/src/main/java/org/apache/kafka/clients/consumer/ConsumerConfig.java
+++ b/clients/src/main/java/org/apache/kafka/clients/consumer/ConsumerConfig.java
@@ -542,7 +542,7 @@ public class ConsumerConfig extends AbstractConfig {
     }
 
     public static ConfigDef configDef() {
-        return  CONFIG;
+        return  new ConfigDef(CONFIG);
     }
 
     public static void main(String[] args) {
diff --git a/clients/src/main/java/org/apache/kafka/clients/producer/ProducerConfig.java b/clients/src/main/java/org/apache/kafka/clients/producer/ProducerConfig.java
index 396d91e..4a4aeba 100644
--- a/clients/src/main/java/org/apache/kafka/clients/producer/ProducerConfig.java
+++ b/clients/src/main/java/org/apache/kafka/clients/producer/ProducerConfig.java
@@ -405,7 +405,7 @@ public class ProducerConfig extends AbstractConfig {
     }
 
     public static ConfigDef configDef() {
-        return  CONFIG;
+        return  new ConfigDef(CONFIG);
     }
 
     public static void main(String[] args) {
diff --git a/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/AllConnectorClientConfigOverridePolicy.java
b/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/AllConnectorClientConfigOverridePolicy.java
index ecd76ba..e808857 100644
--- a/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/AllConnectorClientConfigOverridePolicy.java
+++ b/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/AllConnectorClientConfigOverridePolicy.java
@@ -24,7 +24,7 @@ import org.slf4j.LoggerFactory;
 import java.util.Map;
 
 /**
- * Allows all client configurations to be overridden via the connector configs by setting
{@code client.config.policy} to {@code All}
+ * Allows all client configurations to be overridden via the connector configs by setting
{@code connector.client.config.override.policy} to {@code All}
  */
 public class AllConnectorClientConfigOverridePolicy extends AbstractConnectorClientConfigOverridePolicy
{
     private static final Logger log = LoggerFactory.getLogger(AllConnectorClientConfigOverridePolicy.class);
diff --git a/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/NoneConnectorClientConfigOverridePolicy.java
b/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/NoneConnectorClientConfigOverridePolicy.java
index 8236c89..9b414c4 100644
--- a/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/NoneConnectorClientConfigOverridePolicy.java
+++ b/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/NoneConnectorClientConfigOverridePolicy.java
@@ -24,7 +24,7 @@ import org.slf4j.LoggerFactory;
 import java.util.Map;
 
 /**
- * Disallow any client configuration to be overridden via the connector configs by setting
{@code client.config.policy} to {@code None}.
+ * Disallow any client configuration to be overridden via the connector configs by setting
{@code connector.client.config.override.policy} to {@code None}.
  * This is the default behavior.
  */
 public class NoneConnectorClientConfigOverridePolicy extends AbstractConnectorClientConfigOverridePolicy
{
diff --git a/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/PrincipalConnectorClientConfigOverridePolicy.java
b/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/PrincipalConnectorClientConfigOverridePolicy.java
index 7d80d80..492c5a9 100644
--- a/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/PrincipalConnectorClientConfigOverridePolicy.java
+++ b/connect/runtime/src/main/java/org/apache/kafka/connect/connector/policy/PrincipalConnectorClientConfigOverridePolicy.java
@@ -29,7 +29,7 @@ import java.util.stream.Collectors;
 import java.util.stream.Stream;
 
 /**
- * Allows all {@code sasl} configurations to be overridden via the connector configs by setting
{@code client.config.policy} to
+ * Allows all {@code sasl} configurations to be overridden via the connector configs by setting
{@code connector.client.config.override.policy} to
  * {@code Principal}. This allows to set a principal per connector.
  */
 public class PrincipalConnectorClientConfigOverridePolicy extends AbstractConnectorClientConfigOverridePolicy
{
diff --git a/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/WorkerConfig.java
b/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/WorkerConfig.java
index 773358f..8657510 100644
--- a/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/WorkerConfig.java
+++ b/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/WorkerConfig.java
@@ -212,7 +212,7 @@ public class WorkerConfig extends AbstractConfig {
             + "<code>ConnectRestExtension</code> allows you to inject into Connect's
REST API user defined resources like filters. "
             + "Typically used to add custom capability like logging, security, etc. ";
 
-    public static final String CONNECTOR_CLIENT_POLICY_CLASS_CONFIG = "client.config.policy";
+    public static final String CONNECTOR_CLIENT_POLICY_CLASS_CONFIG = "connector.client.config.override.policy";
     public static final String CONNECTOR_CLIENT_POLICY_CLASS_DOC =
         "Class name or alias of implementation of <code>ConnectorClientConfigOverridePolicy</code>.
Defines what client configurations can be "
         + "overriden by the connector. The default implementation is `None`. The other possible
policies in the framework include `All` "


Mime
View raw message