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/21 06:24:03 UTC
[camel] branch master updated (91feb7a -> 4e50a26)
This is an automated email from the ASF dual-hosted git repository.
acosentino pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git.
from 91feb7a Regen catalog
new 951b184 CAMEL-15310 - AWS* - Support for more than 1 client in the registry - Camel-AWS-CW
new dcefb4b Regen website docs
new 7807c7d Regen catalog
new 79e55b1 CAMEL-15310 - AWS* - Support for more than 1 client in the registry - Camel-AWS2-CW
new 131e5cf Regen website docs
new 4e50a26 Regen catalog
The 6 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../apache/camel/catalog/components/aws-cw.json | 2 ++
.../apache/camel/catalog/components/aws2-cw.json | 2 ++
.../camel/catalog/docs/aws-cw-component.adoc | 6 +++--
.../camel/catalog/docs/aws2-cw-component.adoc | 6 +++--
.../component/aws/cw/CwComponentConfigurer.java | 5 ++++
.../component/aws/cw/CwEndpointConfigurer.java | 5 ++++
.../org/apache/camel/component/aws/cw/aws-cw.json | 2 ++
.../src/main/docs/aws-cw-component.adoc | 6 +++--
.../apache/camel/component/aws/cw/CwComponent.java | 6 +++--
.../camel/component/aws/cw/CwConfiguration.java | 15 ++++++++++++
.../aws/cw/CwComponentRegistryClientTest.java | 24 +++++++++++++++++++
.../component/aws2/cw/Cw2ComponentConfigurer.java | 5 ++++
.../component/aws2/cw/Cw2EndpointConfigurer.java | 5 ++++
.../apache/camel/component/aws2/cw/aws2-cw.json | 2 ++
.../src/main/docs/aws2-cw-component.adoc | 6 +++--
.../camel/component/aws2/cw/Cw2Component.java | 4 +++-
.../camel/component/aws2/cw/Cw2Configuration.java | 15 ++++++++++++
.../aws2/cw/CwComponentRegistryClientTest.java | 24 +++++++++++++++++++
.../dsl/Aws2CwComponentBuilderFactory.java | 16 +++++++++++++
.../dsl/AwsCwComponentBuilderFactory.java | 16 +++++++++++++
.../builder/endpoint/StaticEndpointBuilders.java | 8 +++----
.../endpoint/dsl/Cw2EndpointBuilderFactory.java | 28 ++++++++++++++++++++++
.../endpoint/dsl/CwEndpointBuilderFactory.java | 28 ++++++++++++++++++++++
.../modules/ROOT/pages/aws-cw-component.adoc | 6 +++--
.../modules/ROOT/pages/aws2-cw-component.adoc | 6 +++--
25 files changed, 229 insertions(+), 19 deletions(-)
[camel] 02/06: Regen website docs
Posted by ac...@apache.org.
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 dcefb4bb8a891a88618c76b4d2dcc65d8ffa69b0
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Jul 21 08:14:49 2020 +0200
Regen website docs
---
docs/components/modules/ROOT/pages/aws-cw-component.adoc | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/docs/components/modules/ROOT/pages/aws-cw-component.adoc b/docs/components/modules/ROOT/pages/aws-cw-component.adoc
index bfdbbb2..a15ba98 100644
--- a/docs/components/modules/ROOT/pages/aws-cw-component.adoc
+++ b/docs/components/modules/ROOT/pages/aws-cw-component.adoc
@@ -41,7 +41,7 @@ The metrics will be created if they don't already exists. +
// component options: START
-The AWS CloudWatch component supports 14 options, which are listed below.
+The AWS CloudWatch component supports 15 options, which are listed below.
@@ -49,6 +49,7 @@ The AWS CloudWatch component supports 14 options, which are listed below.
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | AmazonCloudWatch
+| *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) | The component configuration | | CwConfiguration
| *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 [...]
| *name* (producer) | The metric name | | String
@@ -87,13 +88,14 @@ with the following path and query parameters:
|===
-=== Query Parameters (14 parameters):
+=== Query Parameters (15 parameters):
[width="100%",cols="2,5,^1,2",options="header"]
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | AmazonCloudWatch
+| *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 [...]
| *name* (producer) | The metric name | | String
| *proxyHost* (producer) | To define a proxy host when instantiating the CW client | | String
[camel] 04/06: CAMEL-15310 - AWS* - Support for more than 1 client
in the registry - Camel-AWS2-CW
Posted by ac...@apache.org.
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 79e55b1cf9bfcaa9bfa66a482164604242788067
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Jul 21 08:21:45 2020 +0200
CAMEL-15310 - AWS* - Support for more than 1 client in the registry - Camel-AWS2-CW
---
.../component/aws2/cw/Cw2ComponentConfigurer.java | 5 ++++
.../component/aws2/cw/Cw2EndpointConfigurer.java | 5 ++++
.../apache/camel/component/aws2/cw/aws2-cw.json | 2 ++
.../src/main/docs/aws2-cw-component.adoc | 6 +++--
.../camel/component/aws2/cw/Cw2Component.java | 4 +++-
.../camel/component/aws2/cw/Cw2Configuration.java | 15 ++++++++++++
.../aws2/cw/CwComponentRegistryClientTest.java | 24 +++++++++++++++++++
.../dsl/Aws2CwComponentBuilderFactory.java | 16 +++++++++++++
.../builder/endpoint/StaticEndpointBuilders.java | 8 +++----
.../endpoint/dsl/Cw2EndpointBuilderFactory.java | 28 ++++++++++++++++++++++
10 files changed, 106 insertions(+), 7 deletions(-)
diff --git a/components/camel-aws2-cw/src/generated/java/org/apache/camel/component/aws2/cw/Cw2ComponentConfigurer.java b/components/camel-aws2-cw/src/generated/java/org/apache/camel/component/aws2/cw/Cw2ComponentConfigurer.java
index 07838a3..8e66830 100644
--- a/components/camel-aws2-cw/src/generated/java/org/apache/camel/component/aws2/cw/Cw2ComponentConfigurer.java
+++ b/components/camel-aws2-cw/src/generated/java/org/apache/camel/component/aws2/cw/Cw2ComponentConfigurer.java
@@ -30,6 +30,8 @@ public class Cw2ComponentConfigurer extends PropertyConfigurerSupport implements
case "accessKey": getOrCreateConfiguration(target).setAccessKey(property(camelContext, java.lang.String.class, value)); return true;
case "amazoncwclient":
case "amazonCwClient": getOrCreateConfiguration(target).setAmazonCwClient(property(camelContext, software.amazon.awssdk.services.cloudwatch.CloudWatchClient.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.cw.Cw2Configuration.class, value)); return true;
@@ -59,6 +61,7 @@ public class Cw2ComponentConfigurer extends PropertyConfigurerSupport implements
Map<String, Object> answer = new CaseInsensitiveMap();
answer.put("accessKey", java.lang.String.class);
answer.put("amazonCwClient", software.amazon.awssdk.services.cloudwatch.CloudWatchClient.class);
+ answer.put("autoDiscoverClient", boolean.class);
answer.put("basicPropertyBinding", boolean.class);
answer.put("configuration", org.apache.camel.component.aws2.cw.Cw2Configuration.class);
answer.put("lazyStartProducer", boolean.class);
@@ -83,6 +86,8 @@ public class Cw2ComponentConfigurer extends PropertyConfigurerSupport implements
case "accessKey": return getOrCreateConfiguration(target).getAccessKey();
case "amazoncwclient":
case "amazonCwClient": return getOrCreateConfiguration(target).getAmazonCwClient();
+ 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-cw/src/generated/java/org/apache/camel/component/aws2/cw/Cw2EndpointConfigurer.java b/components/camel-aws2-cw/src/generated/java/org/apache/camel/component/aws2/cw/Cw2EndpointConfigurer.java
index febe3db..dfb0bbe 100644
--- a/components/camel-aws2-cw/src/generated/java/org/apache/camel/component/aws2/cw/Cw2EndpointConfigurer.java
+++ b/components/camel-aws2-cw/src/generated/java/org/apache/camel/component/aws2/cw/Cw2EndpointConfigurer.java
@@ -23,6 +23,8 @@ public class Cw2EndpointConfigurer extends PropertyConfigurerSupport implements
case "accessKey": target.getConfiguration().setAccessKey(property(camelContext, java.lang.String.class, value)); return true;
case "amazoncwclient":
case "amazonCwClient": target.getConfiguration().setAmazonCwClient(property(camelContext, software.amazon.awssdk.services.cloudwatch.CloudWatchClient.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":
@@ -52,6 +54,7 @@ public class Cw2EndpointConfigurer extends PropertyConfigurerSupport implements
Map<String, Object> answer = new CaseInsensitiveMap();
answer.put("accessKey", java.lang.String.class);
answer.put("amazonCwClient", software.amazon.awssdk.services.cloudwatch.CloudWatchClient.class);
+ answer.put("autoDiscoverClient", boolean.class);
answer.put("basicPropertyBinding", boolean.class);
answer.put("lazyStartProducer", boolean.class);
answer.put("name", java.lang.String.class);
@@ -76,6 +79,8 @@ public class Cw2EndpointConfigurer extends PropertyConfigurerSupport implements
case "accessKey": return target.getConfiguration().getAccessKey();
case "amazoncwclient":
case "amazonCwClient": return target.getConfiguration().getAmazonCwClient();
+ case "autodiscoverclient":
+ case "autoDiscoverClient": return target.getConfiguration().isAutoDiscoverClient();
case "basicpropertybinding":
case "basicPropertyBinding": return target.isBasicPropertyBinding();
case "lazystartproducer":
diff --git a/components/camel-aws2-cw/src/generated/resources/org/apache/camel/component/aws2/cw/aws2-cw.json b/components/camel-aws2-cw/src/generated/resources/org/apache/camel/component/aws2/cw/aws2-cw.json
index e522642..c5cbbf1 100644
--- a/components/camel-aws2-cw/src/generated/resources/org/apache/camel/component/aws2/cw/aws2-cw.json
+++ b/components/camel-aws2-cw/src/generated/resources/org/apache/camel/component/aws2/cw/aws2-cw.json
@@ -22,6 +22,7 @@
},
"componentProperties": {
"amazonCwClient": { "kind": "property", "displayName": "Amazon Cw Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.cloudwatch.CloudWatchClient", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "To use the AmazonCloudWatch as the client" },
+ "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.cw.Cw2Configuration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registry [...]
"configuration": { "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws2.cw.Cw2Configuration", "deprecated": false, "secret": false, "description": "The 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 [...]
"name": { "kind": "property", "displayName": "Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "The metric name" },
@@ -40,6 +41,7 @@
"properties": {
"namespace": { "kind": "path", "displayName": "Namespace", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "The metric namespace" },
"amazonCwClient": { "kind": "parameter", "displayName": "Amazon Cw Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.cloudwatch.CloudWatchClient", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "To use the AmazonCloudWatch as the client" },
+ "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.cw.Cw2Configuration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registr [...]
"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 [...]
"name": { "kind": "parameter", "displayName": "Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "The metric name" },
"proxyHost": { "kind": "parameter", "displayName": "Proxy Host", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "To define a proxy host when instantiating the CW client" },
diff --git a/components/camel-aws2-cw/src/main/docs/aws2-cw-component.adoc b/components/camel-aws2-cw/src/main/docs/aws2-cw-component.adoc
index 2f327b7..dd1d7e5 100644
--- a/components/camel-aws2-cw/src/main/docs/aws2-cw-component.adoc
+++ b/components/camel-aws2-cw/src/main/docs/aws2-cw-component.adoc
@@ -44,7 +44,7 @@ The metrics will be created if they don't already exists. +
// component options: START
-The AWS 2 CloudWatch component supports 15 options, which are listed below.
+The AWS 2 CloudWatch component supports 16 options, which are listed below.
@@ -52,6 +52,7 @@ The AWS 2 CloudWatch component supports 15 options, which are listed below.
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | CloudWatchClient
+| *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) | The component configuration | | Cw2Configuration
| *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 [...]
| *name* (producer) | The metric name | | String
@@ -91,13 +92,14 @@ with the following path and query parameters:
|===
-=== Query Parameters (15 parameters):
+=== Query Parameters (16 parameters):
[width="100%",cols="2,5,^1,2",options="header"]
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | CloudWatchClient
+| *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 [...]
| *name* (producer) | The metric name | | String
| *proxyHost* (producer) | To define a proxy host when instantiating the CW client | | String
diff --git a/components/camel-aws2-cw/src/main/java/org/apache/camel/component/aws2/cw/Cw2Component.java b/components/camel-aws2-cw/src/main/java/org/apache/camel/component/aws2/cw/Cw2Component.java
index 35f7e17..c4b2720 100644
--- a/components/camel-aws2-cw/src/main/java/org/apache/camel/component/aws2/cw/Cw2Component.java
+++ b/components/camel-aws2-cw/src/main/java/org/apache/camel/component/aws2/cw/Cw2Component.java
@@ -63,7 +63,9 @@ public class Cw2Component extends DefaultComponent {
// parameters
setProperties(endpoint, parameters);
- checkAndSetRegistryClient(configuration, endpoint);
+ if (endpoint.getConfiguration().isAutoDiscoverClient()) {
+ checkAndSetRegistryClient(configuration, endpoint);
+ }
if (configuration.getAmazonCwClient() == null && (configuration.getAccessKey() == null || configuration.getSecretKey() == null)) {
throw new IllegalArgumentException("AmazonCwClient or accessKey and secretKey must be specified");
}
diff --git a/components/camel-aws2-cw/src/main/java/org/apache/camel/component/aws2/cw/Cw2Configuration.java b/components/camel-aws2-cw/src/main/java/org/apache/camel/component/aws2/cw/Cw2Configuration.java
index 5ab1744..7208b9c 100644
--- a/components/camel-aws2-cw/src/main/java/org/apache/camel/component/aws2/cw/Cw2Configuration.java
+++ b/components/camel-aws2-cw/src/main/java/org/apache/camel/component/aws2/cw/Cw2Configuration.java
@@ -56,6 +56,8 @@ public class Cw2Configuration implements Cloneable {
private String region;
@UriParam(defaultValue = "false")
private boolean trustAllCertificates;
+ @UriParam(label = "common", defaultValue = "true")
+ private boolean autoDiscoverClient = true;
public String getAccessKey() {
return accessKey;
@@ -202,6 +204,19 @@ public class Cw2Configuration 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-cw/src/test/java/org/apache/camel/component/aws2/cw/CwComponentRegistryClientTest.java b/components/camel-aws2-cw/src/test/java/org/apache/camel/component/aws2/cw/CwComponentRegistryClientTest.java
index 01152e6..1295c04 100644
--- a/components/camel-aws2-cw/src/test/java/org/apache/camel/component/aws2/cw/CwComponentRegistryClientTest.java
+++ b/components/camel-aws2-cw/src/test/java/org/apache/camel/component/aws2/cw/CwComponentRegistryClientTest.java
@@ -24,6 +24,8 @@ import org.junit.jupiter.api.Test;
import software.amazon.awssdk.services.cloudwatch.CloudWatchClient;
import static org.junit.jupiter.api.Assertions.assertEquals;
+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 CwComponentRegistryClientTest extends CamelTestSupport {
@@ -52,4 +54,26 @@ public class CwComponentRegistryClientTest extends CamelTestSupport {
component.createEndpoint("aws2-cw://camel.apache.org/test");
});
}
+
+ @Test
+ public void createEndpointWithAutoDiscoverFalse() throws Exception {
+ CloudWatchClient cloudWatchClient = new CloudWatchClientMock();
+ context.getRegistry().bind("amazonCwClient", cloudWatchClient);
+ Cw2Component component = context.getComponent("aws2-cw", Cw2Component.class);
+ Cw2Endpoint endpoint = (Cw2Endpoint)component.createEndpoint("aws2-cw://camel.apache.org/test?accessKey=xxx&secretKey=yyy&autoDiscoverClient=false");
+
+ assertEquals("camel.apache.org/test", endpoint.getConfiguration().getNamespace());
+ assertNotSame(cloudWatchClient, endpoint.getConfiguration().getAmazonCwClient());
+ }
+
+ @Test
+ public void createEndpointWithAutoDiscoverTrue() throws Exception {
+ CloudWatchClient cloudWatchClient = new CloudWatchClientMock();
+ context.getRegistry().bind("amazonCwClient", cloudWatchClient);
+ Cw2Component component = context.getComponent("aws2-cw", Cw2Component.class);
+ Cw2Endpoint endpoint = (Cw2Endpoint)component.createEndpoint("aws2-cw://camel.apache.org/test?accessKey=xxx&secretKey=yyy");
+
+ assertEquals("camel.apache.org/test", endpoint.getConfiguration().getNamespace());
+ assertSame(cloudWatchClient, endpoint.getConfiguration().getAmazonCwClient());
+ }
}
diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2CwComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2CwComponentBuilderFactory.java
index 2a5c60a..295bddf 100644
--- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2CwComponentBuilderFactory.java
+++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2CwComponentBuilderFactory.java
@@ -60,6 +60,21 @@ public interface Aws2CwComponentBuilderFactory {
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 is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: common
+ */
+ default Aws2CwComponentBuilder autoDiscoverClient(
+ boolean autoDiscoverClient) {
+ doSetProperty("autoDiscoverClient", autoDiscoverClient);
+ return this;
+ }
+ /**
* The component configuration.
*
* The option is a:
@@ -263,6 +278,7 @@ public interface Aws2CwComponentBuilderFactory {
Object value) {
switch (name) {
case "amazonCwClient": getOrCreateConfiguration((Cw2Component) component).setAmazonCwClient((software.amazon.awssdk.services.cloudwatch.CloudWatchClient) value); return true;
+ case "autoDiscoverClient": getOrCreateConfiguration((Cw2Component) component).setAutoDiscoverClient((boolean) value); return true;
case "configuration": ((Cw2Component) component).setConfiguration((org.apache.camel.component.aws2.cw.Cw2Configuration) value); return true;
case "lazyStartProducer": ((Cw2Component) component).setLazyStartProducer((boolean) value); return true;
case "name": getOrCreateConfiguration((Cw2Component) component).setName((java.lang.String) 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 884a1a6..1c60f30 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
@@ -877,7 +877,7 @@ public class StaticEndpointBuilders {
*
* @param path namespace
*/
- public static org.apache.camel.builder.endpoint.dsl.Cw2EndpointBuilderFactory.Cw2EndpointBuilder aws2Cw(
+ static org.apache.camel.builder.endpoint.dsl.Cw2EndpointBuilderFactory.Cw2EndpointBuilder aws2Cw(
String path) {
return org.apache.camel.builder.endpoint.dsl.Cw2EndpointBuilderFactory.endpointBuilder("aws2-cw", path);
}
@@ -898,7 +898,7 @@ public class StaticEndpointBuilders {
* instead of the default name
* @param path namespace
*/
- public static org.apache.camel.builder.endpoint.dsl.Cw2EndpointBuilderFactory.Cw2EndpointBuilder aws2Cw(
+ static org.apache.camel.builder.endpoint.dsl.Cw2EndpointBuilderFactory.Cw2EndpointBuilder aws2Cw(
String componentName,
String path) {
return org.apache.camel.builder.endpoint.dsl.Cw2EndpointBuilderFactory.endpointBuilder(componentName, path);
@@ -1627,7 +1627,7 @@ public class StaticEndpointBuilders {
*
* @param path namespace
*/
- static org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.CwEndpointBuilder awsCw(
+ public static org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.CwEndpointBuilder awsCw(
String path) {
return org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.endpointBuilder("aws-cw", path);
}
@@ -1648,7 +1648,7 @@ public class StaticEndpointBuilders {
* instead of the default name
* @param path namespace
*/
- static org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.CwEndpointBuilder awsCw(
+ public static org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.CwEndpointBuilder awsCw(
String componentName,
String path) {
return org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.endpointBuilder(componentName, path);
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/Cw2EndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/Cw2EndpointBuilderFactory.java
index eff394b..f6a43d9 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/Cw2EndpointBuilderFactory.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/Cw2EndpointBuilderFactory.java
@@ -63,6 +63,34 @@ public interface Cw2EndpointBuilderFactory {
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 is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: common
+ */
+ default Cw2EndpointBuilder 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 Cw2EndpointBuilder 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
[camel] 03/06: Regen catalog
Posted by ac...@apache.org.
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 7807c7d7bc2a8bf40020d4862978cf9eb79dcf5b
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Jul 21 08:15:25 2020 +0200
Regen catalog
---
.../resources/org/apache/camel/catalog/components/aws-cw.json | 2 ++
.../resources/org/apache/camel/catalog/docs/aws-cw-component.adoc | 6 ++++--
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-cw.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-cw.json
index ca4ebe0..4a7b445 100644
--- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-cw.json
+++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-cw.json
@@ -22,6 +22,7 @@
},
"componentProperties": {
"amazonCwClient": { "kind": "property", "displayName": "Amazon Cw Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.amazonaws.services.cloudwatch.AmazonCloudWatch", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "To use the AmazonCloudWatch as the client" },
+ "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.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registry a [...]
"configuration": { "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws.cw.CwConfiguration", "deprecated": false, "secret": false, "description": "The 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 [...]
"name": { "kind": "property", "displayName": "Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "The metric name" },
@@ -39,6 +40,7 @@
"properties": {
"namespace": { "kind": "path", "displayName": "Namespace", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "The metric namespace" },
"amazonCwClient": { "kind": "parameter", "displayName": "Amazon Cw Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.amazonaws.services.cloudwatch.AmazonCloudWatch", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "To use the AmazonCloudWatch as the client" },
+ "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.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registry [...]
"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 [...]
"name": { "kind": "parameter", "displayName": "Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "The metric name" },
"proxyHost": { "kind": "parameter", "displayName": "Proxy Host", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "To define a proxy host when instantiating the CW client" },
diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws-cw-component.adoc b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws-cw-component.adoc
index 0da1476..ae218f4 100644
--- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws-cw-component.adoc
+++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws-cw-component.adoc
@@ -39,7 +39,7 @@ The metrics will be created if they don't already exists. +
// component options: START
-The AWS CloudWatch component supports 14 options, which are listed below.
+The AWS CloudWatch component supports 15 options, which are listed below.
@@ -47,6 +47,7 @@ The AWS CloudWatch component supports 14 options, which are listed below.
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | AmazonCloudWatch
+| *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) | The component configuration | | CwConfiguration
| *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 [...]
| *name* (producer) | The metric name | | String
@@ -85,13 +86,14 @@ with the following path and query parameters:
|===
-=== Query Parameters (14 parameters):
+=== Query Parameters (15 parameters):
[width="100%",cols="2,5,^1,2",options="header"]
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | AmazonCloudWatch
+| *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 [...]
| *name* (producer) | The metric name | | String
| *proxyHost* (producer) | To define a proxy host when instantiating the CW client | | String
[camel] 06/06: Regen catalog
Posted by ac...@apache.org.
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 4e50a26e53717ad5e71b112446967920cb5d8a0a
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Jul 21 08:23:01 2020 +0200
Regen catalog
---
.../resources/org/apache/camel/catalog/components/aws2-cw.json | 2 ++
.../resources/org/apache/camel/catalog/docs/aws2-cw-component.adoc | 6 ++++--
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws2-cw.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws2-cw.json
index e522642..c5cbbf1 100644
--- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws2-cw.json
+++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws2-cw.json
@@ -22,6 +22,7 @@
},
"componentProperties": {
"amazonCwClient": { "kind": "property", "displayName": "Amazon Cw Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.cloudwatch.CloudWatchClient", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "To use the AmazonCloudWatch as the client" },
+ "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.cw.Cw2Configuration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registry [...]
"configuration": { "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws2.cw.Cw2Configuration", "deprecated": false, "secret": false, "description": "The 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 [...]
"name": { "kind": "property", "displayName": "Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "The metric name" },
@@ -40,6 +41,7 @@
"properties": {
"namespace": { "kind": "path", "displayName": "Namespace", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "The metric namespace" },
"amazonCwClient": { "kind": "parameter", "displayName": "Amazon Cw Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.cloudwatch.CloudWatchClient", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "To use the AmazonCloudWatch as the client" },
+ "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.cw.Cw2Configuration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registr [...]
"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 [...]
"name": { "kind": "parameter", "displayName": "Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "The metric name" },
"proxyHost": { "kind": "parameter", "displayName": "Proxy Host", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.cw.Cw2Configuration", "configurationField": "configuration", "description": "To define a proxy host when instantiating the CW client" },
diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws2-cw-component.adoc b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws2-cw-component.adoc
index 2f327b7..dd1d7e5 100644
--- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws2-cw-component.adoc
+++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws2-cw-component.adoc
@@ -44,7 +44,7 @@ The metrics will be created if they don't already exists. +
// component options: START
-The AWS 2 CloudWatch component supports 15 options, which are listed below.
+The AWS 2 CloudWatch component supports 16 options, which are listed below.
@@ -52,6 +52,7 @@ The AWS 2 CloudWatch component supports 15 options, which are listed below.
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | CloudWatchClient
+| *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) | The component configuration | | Cw2Configuration
| *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 [...]
| *name* (producer) | The metric name | | String
@@ -91,13 +92,14 @@ with the following path and query parameters:
|===
-=== Query Parameters (15 parameters):
+=== Query Parameters (16 parameters):
[width="100%",cols="2,5,^1,2",options="header"]
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | CloudWatchClient
+| *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 [...]
| *name* (producer) | The metric name | | String
| *proxyHost* (producer) | To define a proxy host when instantiating the CW client | | String
[camel] 01/06: CAMEL-15310 - AWS* - Support for more than 1 client
in the registry - Camel-AWS-CW
Posted by ac...@apache.org.
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 951b1840284ca7fd9f4971ddeb85f5081919fd82
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Jul 21 08:13:48 2020 +0200
CAMEL-15310 - AWS* - Support for more than 1 client in the registry - Camel-AWS-CW
---
.../component/aws/cw/CwComponentConfigurer.java | 5 ++++
.../component/aws/cw/CwEndpointConfigurer.java | 5 ++++
.../org/apache/camel/component/aws/cw/aws-cw.json | 2 ++
.../src/main/docs/aws-cw-component.adoc | 6 +++--
.../apache/camel/component/aws/cw/CwComponent.java | 6 +++--
.../camel/component/aws/cw/CwConfiguration.java | 15 ++++++++++++
.../aws/cw/CwComponentRegistryClientTest.java | 24 +++++++++++++++++++
.../dsl/AwsCwComponentBuilderFactory.java | 16 +++++++++++++
.../builder/endpoint/StaticEndpointBuilders.java | 8 +++----
.../endpoint/dsl/CwEndpointBuilderFactory.java | 28 ++++++++++++++++++++++
10 files changed, 107 insertions(+), 8 deletions(-)
diff --git a/components/camel-aws-cw/src/generated/java/org/apache/camel/component/aws/cw/CwComponentConfigurer.java b/components/camel-aws-cw/src/generated/java/org/apache/camel/component/aws/cw/CwComponentConfigurer.java
index c3cb310..ec3f2ce 100644
--- a/components/camel-aws-cw/src/generated/java/org/apache/camel/component/aws/cw/CwComponentConfigurer.java
+++ b/components/camel-aws-cw/src/generated/java/org/apache/camel/component/aws/cw/CwComponentConfigurer.java
@@ -30,6 +30,8 @@ public class CwComponentConfigurer extends PropertyConfigurerSupport implements
case "accessKey": getOrCreateConfiguration(target).setAccessKey(property(camelContext, java.lang.String.class, value)); return true;
case "amazoncwclient":
case "amazonCwClient": getOrCreateConfiguration(target).setAmazonCwClient(property(camelContext, com.amazonaws.services.cloudwatch.AmazonCloudWatch.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.aws.cw.CwConfiguration.class, value)); return true;
@@ -57,6 +59,7 @@ public class CwComponentConfigurer extends PropertyConfigurerSupport implements
Map<String, Object> answer = new CaseInsensitiveMap();
answer.put("accessKey", java.lang.String.class);
answer.put("amazonCwClient", com.amazonaws.services.cloudwatch.AmazonCloudWatch.class);
+ answer.put("autoDiscoverClient", boolean.class);
answer.put("basicPropertyBinding", boolean.class);
answer.put("configuration", org.apache.camel.component.aws.cw.CwConfiguration.class);
answer.put("lazyStartProducer", boolean.class);
@@ -80,6 +83,8 @@ public class CwComponentConfigurer extends PropertyConfigurerSupport implements
case "accessKey": return getOrCreateConfiguration(target).getAccessKey();
case "amazoncwclient":
case "amazonCwClient": return getOrCreateConfiguration(target).getAmazonCwClient();
+ 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-aws-cw/src/generated/java/org/apache/camel/component/aws/cw/CwEndpointConfigurer.java b/components/camel-aws-cw/src/generated/java/org/apache/camel/component/aws/cw/CwEndpointConfigurer.java
index b05d25d..8b86897 100644
--- a/components/camel-aws-cw/src/generated/java/org/apache/camel/component/aws/cw/CwEndpointConfigurer.java
+++ b/components/camel-aws-cw/src/generated/java/org/apache/camel/component/aws/cw/CwEndpointConfigurer.java
@@ -23,6 +23,8 @@ public class CwEndpointConfigurer extends PropertyConfigurerSupport implements G
case "accessKey": target.getConfiguration().setAccessKey(property(camelContext, java.lang.String.class, value)); return true;
case "amazoncwclient":
case "amazonCwClient": target.getConfiguration().setAmazonCwClient(property(camelContext, com.amazonaws.services.cloudwatch.AmazonCloudWatch.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 CwEndpointConfigurer extends PropertyConfigurerSupport implements G
Map<String, Object> answer = new CaseInsensitiveMap();
answer.put("accessKey", java.lang.String.class);
answer.put("amazonCwClient", com.amazonaws.services.cloudwatch.AmazonCloudWatch.class);
+ answer.put("autoDiscoverClient", boolean.class);
answer.put("basicPropertyBinding", boolean.class);
answer.put("lazyStartProducer", boolean.class);
answer.put("name", java.lang.String.class);
@@ -73,6 +76,8 @@ public class CwEndpointConfigurer extends PropertyConfigurerSupport implements G
case "accessKey": return target.getConfiguration().getAccessKey();
case "amazoncwclient":
case "amazonCwClient": return target.getConfiguration().getAmazonCwClient();
+ case "autodiscoverclient":
+ case "autoDiscoverClient": return target.getConfiguration().isAutoDiscoverClient();
case "basicpropertybinding":
case "basicPropertyBinding": return target.isBasicPropertyBinding();
case "lazystartproducer":
diff --git a/components/camel-aws-cw/src/generated/resources/org/apache/camel/component/aws/cw/aws-cw.json b/components/camel-aws-cw/src/generated/resources/org/apache/camel/component/aws/cw/aws-cw.json
index ca4ebe0..4a7b445 100644
--- a/components/camel-aws-cw/src/generated/resources/org/apache/camel/component/aws/cw/aws-cw.json
+++ b/components/camel-aws-cw/src/generated/resources/org/apache/camel/component/aws/cw/aws-cw.json
@@ -22,6 +22,7 @@
},
"componentProperties": {
"amazonCwClient": { "kind": "property", "displayName": "Amazon Cw Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.amazonaws.services.cloudwatch.AmazonCloudWatch", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "To use the AmazonCloudWatch as the client" },
+ "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.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registry a [...]
"configuration": { "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws.cw.CwConfiguration", "deprecated": false, "secret": false, "description": "The 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 [...]
"name": { "kind": "property", "displayName": "Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "The metric name" },
@@ -39,6 +40,7 @@
"properties": {
"namespace": { "kind": "path", "displayName": "Namespace", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "The metric namespace" },
"amazonCwClient": { "kind": "parameter", "displayName": "Amazon Cw Client", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.amazonaws.services.cloudwatch.AmazonCloudWatch", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "To use the AmazonCloudWatch as the client" },
+ "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.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client instance in the registry [...]
"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 [...]
"name": { "kind": "parameter", "displayName": "Name", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "The metric name" },
"proxyHost": { "kind": "parameter", "displayName": "Proxy Host", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.cw.CwConfiguration", "configurationField": "configuration", "description": "To define a proxy host when instantiating the CW client" },
diff --git a/components/camel-aws-cw/src/main/docs/aws-cw-component.adoc b/components/camel-aws-cw/src/main/docs/aws-cw-component.adoc
index 0da1476..ae218f4 100644
--- a/components/camel-aws-cw/src/main/docs/aws-cw-component.adoc
+++ b/components/camel-aws-cw/src/main/docs/aws-cw-component.adoc
@@ -39,7 +39,7 @@ The metrics will be created if they don't already exists. +
// component options: START
-The AWS CloudWatch component supports 14 options, which are listed below.
+The AWS CloudWatch component supports 15 options, which are listed below.
@@ -47,6 +47,7 @@ The AWS CloudWatch component supports 14 options, which are listed below.
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | AmazonCloudWatch
+| *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) | The component configuration | | CwConfiguration
| *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 [...]
| *name* (producer) | The metric name | | String
@@ -85,13 +86,14 @@ with the following path and query parameters:
|===
-=== Query Parameters (14 parameters):
+=== Query Parameters (15 parameters):
[width="100%",cols="2,5,^1,2",options="header"]
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | AmazonCloudWatch
+| *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 [...]
| *name* (producer) | The metric name | | String
| *proxyHost* (producer) | To define a proxy host when instantiating the CW client | | String
diff --git a/components/camel-aws-cw/src/main/java/org/apache/camel/component/aws/cw/CwComponent.java b/components/camel-aws-cw/src/main/java/org/apache/camel/component/aws/cw/CwComponent.java
index f90308b..ac61ebd 100644
--- a/components/camel-aws-cw/src/main/java/org/apache/camel/component/aws/cw/CwComponent.java
+++ b/components/camel-aws-cw/src/main/java/org/apache/camel/component/aws/cw/CwComponent.java
@@ -52,8 +52,10 @@ public class CwComponent extends DefaultComponent {
CwEndpoint endpoint = new CwEndpoint(uri, this, configuration);
setProperties(endpoint, parameters);
-
- checkAndSetRegistryClient(configuration);
+
+ if (endpoint.getConfiguration().isAutoDiscoverClient()) {
+ checkAndSetRegistryClient(configuration);
+ }
if (configuration.getAmazonCwClient() == null && (configuration.getAccessKey() == null || configuration.getSecretKey() == null)) {
throw new IllegalArgumentException("AmazonCwClient or accessKey and secretKey must be specified");
}
diff --git a/components/camel-aws-cw/src/main/java/org/apache/camel/component/aws/cw/CwConfiguration.java b/components/camel-aws-cw/src/main/java/org/apache/camel/component/aws/cw/CwConfiguration.java
index 76a57b0..4fb815a 100644
--- a/components/camel-aws-cw/src/main/java/org/apache/camel/component/aws/cw/CwConfiguration.java
+++ b/components/camel-aws-cw/src/main/java/org/apache/camel/component/aws/cw/CwConfiguration.java
@@ -53,6 +53,8 @@ public class CwConfiguration implements Cloneable {
private Integer proxyPort;
@UriParam
private String region;
+ @UriParam(label = "common", defaultValue = "true")
+ private boolean autoDiscoverClient = true;
public String getAccessKey() {
return accessKey;
@@ -186,6 +188,19 @@ public class CwConfiguration implements Cloneable {
public void setRegion(String region) {
this.region = region;
}
+
+ 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-aws-cw/src/test/java/org/apache/camel/component/aws/cw/CwComponentRegistryClientTest.java b/components/camel-aws-cw/src/test/java/org/apache/camel/component/aws/cw/CwComponentRegistryClientTest.java
index af7c117..4696d1f 100644
--- a/components/camel-aws-cw/src/test/java/org/apache/camel/component/aws/cw/CwComponentRegistryClientTest.java
+++ b/components/camel-aws-cw/src/test/java/org/apache/camel/component/aws/cw/CwComponentRegistryClientTest.java
@@ -24,6 +24,8 @@ import org.apache.camel.test.junit5.CamelTestSupport;
import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertNotSame;
+import static org.junit.jupiter.api.Assertions.assertSame;
import static org.junit.jupiter.api.Assertions.assertThrows;
import static org.mockito.Mockito.mock;
@@ -52,4 +54,26 @@ public class CwComponentRegistryClientTest extends CamelTestSupport {
assertThrows(IllegalArgumentException.class,
() -> component.createEndpoint("aws-cw://camel.apache.org/test"));
}
+
+ @Test
+ public void createEndpointWithAutoDiscoverClientFalse() throws Exception {
+ AmazonCloudWatchClient cloudWatchClient = mock(AmazonCloudWatchClient.class);
+ context.getRegistry().bind("amazonCwClient", cloudWatchClient);
+ CwComponent component = context.getComponent("aws-cw", CwComponent.class);
+ CwEndpoint endpoint = (CwEndpoint) component.createEndpoint("aws-cw://camel.apache.org/test?accessKey=xxx&secretKey=yyy&autoDiscoverClient=false");
+
+ assertEquals("camel.apache.org/test", endpoint.getConfiguration().getNamespace());
+ assertNotSame(cloudWatchClient, endpoint.getConfiguration().getAmazonCwClient());
+ }
+
+ @Test
+ public void createEndpointWithAutoDiscoverClientTrue() throws Exception {
+ AmazonCloudWatchClient cloudWatchClient = mock(AmazonCloudWatchClient.class);
+ context.getRegistry().bind("amazonCwClient", cloudWatchClient);
+ CwComponent component = context.getComponent("aws-cw", CwComponent.class);
+ CwEndpoint endpoint = (CwEndpoint) component.createEndpoint("aws-cw://camel.apache.org/test?accessKey=xxx&secretKey=yyy");
+
+ assertEquals("camel.apache.org/test", endpoint.getConfiguration().getNamespace());
+ assertSame(cloudWatchClient, endpoint.getConfiguration().getAmazonCwClient());
+ }
}
diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/AwsCwComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/AwsCwComponentBuilderFactory.java
index 6ce9731..38216cc 100644
--- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/AwsCwComponentBuilderFactory.java
+++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/AwsCwComponentBuilderFactory.java
@@ -60,6 +60,21 @@ public interface AwsCwComponentBuilderFactory {
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 is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: common
+ */
+ default AwsCwComponentBuilder autoDiscoverClient(
+ boolean autoDiscoverClient) {
+ doSetProperty("autoDiscoverClient", autoDiscoverClient);
+ return this;
+ }
+ /**
* The component configuration.
*
* The option is a:
@@ -247,6 +262,7 @@ public interface AwsCwComponentBuilderFactory {
Object value) {
switch (name) {
case "amazonCwClient": getOrCreateConfiguration((CwComponent) component).setAmazonCwClient((com.amazonaws.services.cloudwatch.AmazonCloudWatch) value); return true;
+ case "autoDiscoverClient": getOrCreateConfiguration((CwComponent) component).setAutoDiscoverClient((boolean) value); return true;
case "configuration": ((CwComponent) component).setConfiguration((org.apache.camel.component.aws.cw.CwConfiguration) value); return true;
case "lazyStartProducer": ((CwComponent) component).setLazyStartProducer((boolean) value); return true;
case "name": getOrCreateConfiguration((CwComponent) component).setName((java.lang.String) 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 5031310..884a1a6 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
@@ -1417,7 +1417,7 @@ public class StaticEndpointBuilders {
*
* @param path //bucketNameOrArn
*/
- static org.apache.camel.builder.endpoint.dsl.AWS2S3EndpointBuilderFactory.AWS2S3EndpointBuilder aws2S3(
+ public static org.apache.camel.builder.endpoint.dsl.AWS2S3EndpointBuilderFactory.AWS2S3EndpointBuilder aws2S3(
String path) {
return org.apache.camel.builder.endpoint.dsl.AWS2S3EndpointBuilderFactory.endpointBuilder("aws2-s3", path);
}
@@ -1439,7 +1439,7 @@ public class StaticEndpointBuilders {
* instead of the default name
* @param path //bucketNameOrArn
*/
- static org.apache.camel.builder.endpoint.dsl.AWS2S3EndpointBuilderFactory.AWS2S3EndpointBuilder aws2S3(
+ public static org.apache.camel.builder.endpoint.dsl.AWS2S3EndpointBuilderFactory.AWS2S3EndpointBuilder aws2S3(
String componentName,
String path) {
return org.apache.camel.builder.endpoint.dsl.AWS2S3EndpointBuilderFactory.endpointBuilder(componentName, path);
@@ -1627,7 +1627,7 @@ public class StaticEndpointBuilders {
*
* @param path namespace
*/
- public static org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.CwEndpointBuilder awsCw(
+ static org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.CwEndpointBuilder awsCw(
String path) {
return org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.endpointBuilder("aws-cw", path);
}
@@ -1648,7 +1648,7 @@ public class StaticEndpointBuilders {
* instead of the default name
* @param path namespace
*/
- public static org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.CwEndpointBuilder awsCw(
+ static org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.CwEndpointBuilder awsCw(
String componentName,
String path) {
return org.apache.camel.builder.endpoint.dsl.CwEndpointBuilderFactory.endpointBuilder(componentName, path);
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/CwEndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/CwEndpointBuilderFactory.java
index 02d531a..528233d 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/CwEndpointBuilderFactory.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/CwEndpointBuilderFactory.java
@@ -63,6 +63,34 @@ public interface CwEndpointBuilderFactory {
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 is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: common
+ */
+ default CwEndpointBuilder 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 CwEndpointBuilder 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
[camel] 05/06: Regen website docs
Posted by ac...@apache.org.
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 131e5cf27b7bd2c7944c77eaafbc7abba2a70cb0
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Tue Jul 21 08:22:37 2020 +0200
Regen website docs
---
docs/components/modules/ROOT/pages/aws2-cw-component.adoc | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/docs/components/modules/ROOT/pages/aws2-cw-component.adoc b/docs/components/modules/ROOT/pages/aws2-cw-component.adoc
index cbb457d..f47a456 100644
--- a/docs/components/modules/ROOT/pages/aws2-cw-component.adoc
+++ b/docs/components/modules/ROOT/pages/aws2-cw-component.adoc
@@ -46,7 +46,7 @@ The metrics will be created if they don't already exists. +
// component options: START
-The AWS 2 CloudWatch component supports 15 options, which are listed below.
+The AWS 2 CloudWatch component supports 16 options, which are listed below.
@@ -54,6 +54,7 @@ The AWS 2 CloudWatch component supports 15 options, which are listed below.
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | CloudWatchClient
+| *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) | The component configuration | | Cw2Configuration
| *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 [...]
| *name* (producer) | The metric name | | String
@@ -93,13 +94,14 @@ with the following path and query parameters:
|===
-=== Query Parameters (15 parameters):
+=== Query Parameters (16 parameters):
[width="100%",cols="2,5,^1,2",options="header"]
|===
| Name | Description | Default | Type
| *amazonCwClient* (producer) | To use the AmazonCloudWatch as the client | | CloudWatchClient
+| *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 [...]
| *name* (producer) | The metric name | | String
| *proxyHost* (producer) | To define a proxy host when instantiating the CW client | | String