You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2020/07/24 12:12:07 UTC

[camel] 04/06: CAMEL-15310 - AWS* - Support for more than 1 client in the registry - Camel-AWS2-MSK

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

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 9c4a443cb0844ad1eb2648d37822848da4101055
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Jul 24 14:10:03 2020 +0200

    CAMEL-15310 - AWS* - Support for more than 1 client in the registry - Camel-AWS2-MSK
---
 .../aws2/msk/MSK2ComponentConfigurer.java          |  5 ++++
 .../component/aws2/msk/MSK2EndpointConfigurer.java |  5 ++++
 .../apache/camel/component/aws2/msk/aws2-msk.json  |  2 ++
 .../src/main/docs/aws2-msk-component.adoc          |  6 +++--
 .../camel/component/aws2/msk/MSK2Component.java    |  4 ++-
 .../component/aws2/msk/MSK2Configuration.java      | 16 ++++++++++++
 .../aws2/msk/MSKComponentClientRegistryTest.java   | 24 ++++++++++++++++++
 .../dsl/Aws2MskComponentBuilderFactory.java        | 16 ++++++++++++
 .../builder/endpoint/StaticEndpointBuilders.java   |  8 +++---
 .../endpoint/dsl/MSK2EndpointBuilderFactory.java   | 29 ++++++++++++++++++++++
 10 files changed, 108 insertions(+), 7 deletions(-)

diff --git a/components/camel-aws2-msk/src/generated/java/org/apache/camel/component/aws2/msk/MSK2ComponentConfigurer.java b/components/camel-aws2-msk/src/generated/java/org/apache/camel/component/aws2/msk/MSK2ComponentConfigurer.java
index 7eff302..697bd09 100644
--- a/components/camel-aws2-msk/src/generated/java/org/apache/camel/component/aws2/msk/MSK2ComponentConfigurer.java
+++ b/components/camel-aws2-msk/src/generated/java/org/apache/camel/component/aws2/msk/MSK2ComponentConfigurer.java
@@ -28,6 +28,8 @@ public class MSK2ComponentConfigurer extends PropertyConfigurerSupport implement
         switch (ignoreCase ? name.toLowerCase() : name) {
         case "accesskey":
         case "accessKey": getOrCreateConfiguration(target).setAccessKey(property(camelContext, java.lang.String.class, value)); return true;
+        case "autodiscoverclient":
+        case "autoDiscoverClient": getOrCreateConfiguration(target).setAutoDiscoverClient(property(camelContext, boolean.class, value)); return true;
         case "basicpropertybinding":
         case "basicPropertyBinding": target.setBasicPropertyBinding(property(camelContext, boolean.class, value)); return true;
         case "configuration": target.setConfiguration(property(camelContext, org.apache.camel.component.aws2.msk.MSK2Configuration.class, value)); return true;
@@ -57,6 +59,7 @@ public class MSK2ComponentConfigurer extends PropertyConfigurerSupport implement
     public Map<String, Object> getAllOptions(Object target) {
         Map<String, Object> answer = new CaseInsensitiveMap();
         answer.put("accessKey", java.lang.String.class);
+        answer.put("autoDiscoverClient", boolean.class);
         answer.put("basicPropertyBinding", boolean.class);
         answer.put("configuration", org.apache.camel.component.aws2.msk.MSK2Configuration.class);
         answer.put("lazyStartProducer", boolean.class);
@@ -78,6 +81,8 @@ public class MSK2ComponentConfigurer extends PropertyConfigurerSupport implement
         switch (ignoreCase ? name.toLowerCase() : name) {
         case "accesskey":
         case "accessKey": return getOrCreateConfiguration(target).getAccessKey();
+        case "autodiscoverclient":
+        case "autoDiscoverClient": return getOrCreateConfiguration(target).isAutoDiscoverClient();
         case "basicpropertybinding":
         case "basicPropertyBinding": return target.isBasicPropertyBinding();
         case "configuration": return target.getConfiguration();
diff --git a/components/camel-aws2-msk/src/generated/java/org/apache/camel/component/aws2/msk/MSK2EndpointConfigurer.java b/components/camel-aws2-msk/src/generated/java/org/apache/camel/component/aws2/msk/MSK2EndpointConfigurer.java
index c92cc56..e783ee4 100644
--- a/components/camel-aws2-msk/src/generated/java/org/apache/camel/component/aws2/msk/MSK2EndpointConfigurer.java
+++ b/components/camel-aws2-msk/src/generated/java/org/apache/camel/component/aws2/msk/MSK2EndpointConfigurer.java
@@ -21,6 +21,8 @@ public class MSK2EndpointConfigurer extends PropertyConfigurerSupport implements
         switch (ignoreCase ? name.toLowerCase() : name) {
         case "accesskey":
         case "accessKey": target.getConfiguration().setAccessKey(property(camelContext, java.lang.String.class, value)); return true;
+        case "autodiscoverclient":
+        case "autoDiscoverClient": target.getConfiguration().setAutoDiscoverClient(property(camelContext, boolean.class, value)); return true;
         case "basicpropertybinding":
         case "basicPropertyBinding": target.setBasicPropertyBinding(property(camelContext, boolean.class, value)); return true;
         case "lazystartproducer":
@@ -50,6 +52,7 @@ public class MSK2EndpointConfigurer extends PropertyConfigurerSupport implements
     public Map<String, Object> getAllOptions(Object target) {
         Map<String, Object> answer = new CaseInsensitiveMap();
         answer.put("accessKey", java.lang.String.class);
+        answer.put("autoDiscoverClient", boolean.class);
         answer.put("basicPropertyBinding", boolean.class);
         answer.put("lazyStartProducer", boolean.class);
         answer.put("mskClient", software.amazon.awssdk.services.kafka.KafkaClient.class);
@@ -71,6 +74,8 @@ public class MSK2EndpointConfigurer extends PropertyConfigurerSupport implements
         switch (ignoreCase ? name.toLowerCase() : name) {
         case "accesskey":
         case "accessKey": return target.getConfiguration().getAccessKey();
+        case "autodiscoverclient":
+        case "autoDiscoverClient": return target.getConfiguration().isAutoDiscoverClient();
         case "basicpropertybinding":
         case "basicPropertyBinding": return target.isBasicPropertyBinding();
         case "lazystartproducer":
diff --git a/components/camel-aws2-msk/src/generated/resources/org/apache/camel/component/aws2/msk/aws2-msk.json b/components/camel-aws2-msk/src/generated/resources/org/apache/camel/component/aws2/msk/aws2-msk.json
index 6fe6baf..c6ed6f9 100644
--- a/components/camel-aws2-msk/src/generated/resources/org/apache/camel/component/aws2/msk/aws2-msk.json
+++ b/components/camel-aws2-msk/src/generated/resources/org/apache/camel/component/aws2/msk/aws2-msk.json
@@ -21,6 +21,7 @@
     "lenientProperties": false
   },
   "componentProperties": {
+    "autoDiscoverClient": { "kind": "property", "displayName": "Auto Discover Client", "group": "common", "label": "common", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": "true", "configurationClass": "org.apache.camel.component.aws2.msk.MSK2Configuration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the regist [...]
     "configuration": { "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws2.msk.MSK2Configuration", "deprecated": false, "secret": false, "description": "Component configuration" },
     "lazyStartProducer": { "kind": "property", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the r [...]
     "mskClient": { "kind": "property", "displayName": "Msk Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.kafka.KafkaClient", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.msk.MSK2Configuration", "configurationField": "configuration", "description": "To use a existing configured AWS MSK as client" },
@@ -37,6 +38,7 @@
   },
   "properties": {
     "label": { "kind": "path", "displayName": "Label", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "secret": false, "configurationClass": "org.apache.camel.component.aws2.msk.MSK2Configuration", "configurationField": "configuration", "description": "Logical name" },
+    "autoDiscoverClient": { "kind": "parameter", "displayName": "Auto Discover Client", "group": "common", "label": "common", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": "true", "configurationClass": "org.apache.camel.component.aws2.msk.MSK2Configuration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the regis [...]
     "lazyStartProducer": { "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the  [...]
     "mskClient": { "kind": "parameter", "displayName": "Msk Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.kafka.KafkaClient", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.msk.MSK2Configuration", "configurationField": "configuration", "description": "To use a existing configured AWS MSK as client" },
     "operation": { "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws2.msk.MSK2Operations", "enum": [ "listClusters", "createCluster", "deleteCluster", "describeCluster" ], "deprecated": false, "deprecationNote": "", "secret": false, "configurationClass": "org.apache.camel.component.aws2.msk.MSK2Configuration", "configurationField": "configuration", "description": "The operatio [...]
diff --git a/components/camel-aws2-msk/src/main/docs/aws2-msk-component.adoc b/components/camel-aws2-msk/src/main/docs/aws2-msk-component.adoc
index 7127708..42665df 100644
--- a/components/camel-aws2-msk/src/main/docs/aws2-msk-component.adoc
+++ b/components/camel-aws2-msk/src/main/docs/aws2-msk-component.adoc
@@ -41,13 +41,14 @@ You can append query options to the URI in the following format,
 
 
 // component options: START
-The AWS 2 Managed Streaming for Apache Kafka (MSK) component supports 13 options, which are listed below.
+The AWS 2 Managed Streaming for Apache Kafka (MSK) component supports 14 options, which are listed below.
 
 
 
 [width="100%",cols="2,5,^1,2",options="header"]
 |===
 | Name | Description | Default | Type
+| *autoDiscoverClient* (common) | Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registry automatically otherwise it will skip that checking. | true | boolean
 | *configuration* (producer) | Component configuration |  | MSK2Configuration
 | *lazyStartProducer* (producer) | Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and [...]
 | *mskClient* (producer) | To use a existing configured AWS MSK as client |  | KafkaClient
@@ -86,12 +87,13 @@ with the following path and query parameters:
 |===
 
 
-=== Query Parameters (13 parameters):
+=== Query Parameters (14 parameters):
 
 
 [width="100%",cols="2,5,^1,2",options="header"]
 |===
 | Name | Description | Default | Type
+| *autoDiscoverClient* (common) | Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registry automatically otherwise it will skip that checking. | true | boolean
 | *lazyStartProducer* (producer) | Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and [...]
 | *mskClient* (producer) | To use a existing configured AWS MSK as client |  | KafkaClient
 | *operation* (producer) | *Required* The operation to perform. The value can be one of: listClusters, createCluster, deleteCluster, describeCluster |  | MSK2Operations
diff --git a/components/camel-aws2-msk/src/main/java/org/apache/camel/component/aws2/msk/MSK2Component.java b/components/camel-aws2-msk/src/main/java/org/apache/camel/component/aws2/msk/MSK2Component.java
index 396ab59..69f1045 100644
--- a/components/camel-aws2-msk/src/main/java/org/apache/camel/component/aws2/msk/MSK2Component.java
+++ b/components/camel-aws2-msk/src/main/java/org/apache/camel/component/aws2/msk/MSK2Component.java
@@ -55,7 +55,9 @@ public class MSK2Component extends DefaultComponent {
         MSK2Configuration configuration = this.configuration != null ? this.configuration.copy() : new MSK2Configuration();
         MSK2Endpoint endpoint = new MSK2Endpoint(uri, this, configuration);
         setProperties(endpoint, parameters);
-        checkAndSetRegistryClient(configuration, endpoint);
+        if (endpoint.getConfiguration().isAutoDiscoverClient()) {
+            checkAndSetRegistryClient(configuration, endpoint);
+        }
         if (configuration.getMskClient() == null && (configuration.getAccessKey() == null || configuration.getSecretKey() == null)) {
             throw new IllegalArgumentException("Amazon msk client or accessKey and secretKey must be specified");
         }
diff --git a/components/camel-aws2-msk/src/main/java/org/apache/camel/component/aws2/msk/MSK2Configuration.java b/components/camel-aws2-msk/src/main/java/org/apache/camel/component/aws2/msk/MSK2Configuration.java
index 42944aa..8d34a01 100644
--- a/components/camel-aws2-msk/src/main/java/org/apache/camel/component/aws2/msk/MSK2Configuration.java
+++ b/components/camel-aws2-msk/src/main/java/org/apache/camel/component/aws2/msk/MSK2Configuration.java
@@ -51,6 +51,8 @@ public class MSK2Configuration implements Cloneable {
     private boolean pojoRequest;
     @UriParam(defaultValue = "false")
     private boolean trustAllCertificates;
+    @UriParam(label = "common", defaultValue = "true")
+    private boolean autoDiscoverClient = true;
 
     public KafkaClient getMskClient() {
         return mskClient;
@@ -163,6 +165,20 @@ public class MSK2Configuration implements Cloneable {
     public void setTrustAllCertificates(boolean trustAllCertificates) {
         this.trustAllCertificates = trustAllCertificates;
     }
+    
+    public boolean isAutoDiscoverClient() {
+        return autoDiscoverClient;
+    }
+
+    /**
+     * Setting the autoDiscoverClient mechanism, if true, the component will
+     * look for a client instance in the registry automatically otherwise it
+     * will skip that checking.
+     */
+    public void setAutoDiscoverClient(boolean autoDiscoverClient) {
+        this.autoDiscoverClient = autoDiscoverClient;
+    }
+
 
     // *************************************************
     //
diff --git a/components/camel-aws2-msk/src/test/java/org/apache/camel/component/aws2/msk/MSKComponentClientRegistryTest.java b/components/camel-aws2-msk/src/test/java/org/apache/camel/component/aws2/msk/MSKComponentClientRegistryTest.java
index fec11d3..2504caf 100644
--- a/components/camel-aws2-msk/src/test/java/org/apache/camel/component/aws2/msk/MSKComponentClientRegistryTest.java
+++ b/components/camel-aws2-msk/src/test/java/org/apache/camel/component/aws2/msk/MSKComponentClientRegistryTest.java
@@ -20,6 +20,8 @@ import org.apache.camel.test.junit5.CamelTestSupport;
 import org.junit.jupiter.api.Test;
 
 import static org.junit.jupiter.api.Assertions.assertNotNull;
+import static org.junit.jupiter.api.Assertions.assertNotSame;
+import static org.junit.jupiter.api.Assertions.assertSame;
 import static org.junit.jupiter.api.Assertions.assertThrows;
 
 public class MSKComponentClientRegistryTest extends CamelTestSupport {
@@ -43,4 +45,26 @@ public class MSKComponentClientRegistryTest extends CamelTestSupport {
             component.createEndpoint("aws2-msk://label");
         });
     }
+    
+    @Test
+    public void createEndpointWithAutoDiscoverClientFalse() throws Exception {
+
+        AmazonMSKClientMock awsMSKClient = new AmazonMSKClientMock();
+        context.getRegistry().bind("awsMskClient", awsMSKClient);
+        MSK2Component component = context.getComponent("aws2-msk", MSK2Component.class);
+        MSK2Endpoint endpoint = (MSK2Endpoint) component.createEndpoint("aws-msk://label?accessKey=xxx&secretKey=yyy&autoDiscoverClient=false");
+
+        assertNotSame(awsMSKClient, endpoint.getConfiguration().getMskClient());
+    }
+    
+    @Test
+    public void createEndpointWithAutoDiscoverClientTrue() throws Exception {
+
+        AmazonMSKClientMock awsMSKClient = new AmazonMSKClientMock();
+        context.getRegistry().bind("awsMskClient", awsMSKClient);
+        MSK2Component component = context.getComponent("aws2-msk", MSK2Component.class);
+        MSK2Endpoint endpoint = (MSK2Endpoint) component.createEndpoint("aws2-msk://label?accessKey=xxx&secretKey=yyy");
+
+        assertSame(awsMSKClient, endpoint.getConfiguration().getMskClient());
+    }
 }
diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2MskComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2MskComponentBuilderFactory.java
index d9bff6b..6a35da1 100644
--- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2MskComponentBuilderFactory.java
+++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2MskComponentBuilderFactory.java
@@ -47,6 +47,21 @@ public interface Aws2MskComponentBuilderFactory {
      */
     interface Aws2MskComponentBuilder extends ComponentBuilder<MSK2Component> {
         /**
+         * Setting the autoDiscoverClient mechanism, if true, the component will
+         * look for a client instance in the registry automatically otherwise it
+         * will skip that checking.
+         * 
+         * The option is a: <code>boolean</code> type.
+         * 
+         * Default: true
+         * Group: common
+         */
+        default Aws2MskComponentBuilder autoDiscoverClient(
+                boolean autoDiscoverClient) {
+            doSetProperty("autoDiscoverClient", autoDiscoverClient);
+            return this;
+        }
+        /**
          * Component configuration.
          * 
          * The option is a:
@@ -243,6 +258,7 @@ public interface Aws2MskComponentBuilderFactory {
                 String name,
                 Object value) {
             switch (name) {
+            case "autoDiscoverClient": getOrCreateConfiguration((MSK2Component) component).setAutoDiscoverClient((boolean) value); return true;
             case "configuration": ((MSK2Component) component).setConfiguration((org.apache.camel.component.aws2.msk.MSK2Configuration) value); return true;
             case "lazyStartProducer": ((MSK2Component) component).setLazyStartProducer((boolean) value); return true;
             case "mskClient": getOrCreateConfiguration((MSK2Component) component).setMskClient((software.amazon.awssdk.services.kafka.KafkaClient) value); return true;
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
index 90049fb..0c349fe 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
@@ -1375,7 +1375,7 @@ public class StaticEndpointBuilders {
      * 
      * @param path label
      */
-    public static org.apache.camel.builder.endpoint.dsl.MSK2EndpointBuilderFactory.MSK2EndpointBuilder aws2Msk(
+    static org.apache.camel.builder.endpoint.dsl.MSK2EndpointBuilderFactory.MSK2EndpointBuilder aws2Msk(
             String path) {
         return org.apache.camel.builder.endpoint.dsl.MSK2EndpointBuilderFactory.endpointBuilder("aws2-msk", path);
     }
@@ -1396,7 +1396,7 @@ public class StaticEndpointBuilders {
      * instead of the default name
      * @param path label
      */
-    public static org.apache.camel.builder.endpoint.dsl.MSK2EndpointBuilderFactory.MSK2EndpointBuilder aws2Msk(
+    static org.apache.camel.builder.endpoint.dsl.MSK2EndpointBuilderFactory.MSK2EndpointBuilder aws2Msk(
             String componentName,
             String path) {
         return org.apache.camel.builder.endpoint.dsl.MSK2EndpointBuilderFactory.endpointBuilder(componentName, path);
@@ -2119,7 +2119,7 @@ public class StaticEndpointBuilders {
      * 
      * @param path label
      */
-    static org.apache.camel.builder.endpoint.dsl.MSKEndpointBuilderFactory.MSKEndpointBuilder awsMsk(
+    public static org.apache.camel.builder.endpoint.dsl.MSKEndpointBuilderFactory.MSKEndpointBuilder awsMsk(
             String path) {
         return org.apache.camel.builder.endpoint.dsl.MSKEndpointBuilderFactory.endpointBuilder("aws-msk", path);
     }
@@ -2140,7 +2140,7 @@ public class StaticEndpointBuilders {
      * instead of the default name
      * @param path label
      */
-    static org.apache.camel.builder.endpoint.dsl.MSKEndpointBuilderFactory.MSKEndpointBuilder awsMsk(
+    public static org.apache.camel.builder.endpoint.dsl.MSKEndpointBuilderFactory.MSKEndpointBuilder awsMsk(
             String componentName,
             String path) {
         return org.apache.camel.builder.endpoint.dsl.MSKEndpointBuilderFactory.endpointBuilder(componentName, path);
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/MSK2EndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/MSK2EndpointBuilderFactory.java
index a4f4253..690e00d 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/MSK2EndpointBuilderFactory.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/MSK2EndpointBuilderFactory.java
@@ -39,6 +39,35 @@ public interface MSK2EndpointBuilderFactory {
             return (AdvancedMSK2EndpointBuilder) this;
         }
         /**
+         * Setting the autoDiscoverClient mechanism, if true, the component will
+         * look for a client instance in the registry automatically otherwise it
+         * will skip that checking.
+         * 
+         * The option is a: <code>boolean</code> type.
+         * 
+         * Default: true
+         * Group: common
+         */
+        default MSK2EndpointBuilder autoDiscoverClient(
+                boolean autoDiscoverClient) {
+            doSetProperty("autoDiscoverClient", autoDiscoverClient);
+            return this;
+        }
+        /**
+         * Setting the autoDiscoverClient mechanism, if true, the component will
+         * look for a client instance in the registry automatically otherwise it
+         * will skip that checking.
+         * 
+         * The option will be converted to a <code>boolean</code> type.
+         * 
+         * Default: true
+         * Group: common
+         */
+        default MSK2EndpointBuilder autoDiscoverClient(String autoDiscoverClient) {
+            doSetProperty("autoDiscoverClient", autoDiscoverClient);
+            return this;
+        }
+        /**
          * Whether the producer should be started lazy (on the first message).
          * By starting lazy you can use this to allow CamelContext and routes to
          * startup in situations where a producer may otherwise fail during