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 fdf7dc1d1cc4d4b14f6115a47fafe2a765756dab Author: Andrea Cosentino <[email protected]> AuthorDate: Fri Nov 13 14:30:19 2020 +0100 CAMEL-15836 - Camel-AWS2-EC2: enable autowire on the Ec2 client, regen component --- .../camel/catalog/docs/aws2-ec2-component.adoc | 10 +++----- .../aws2/ec2/AWS2EC2ComponentConfigurer.java | 11 ++++---- .../aws2/ec2/AWS2EC2EndpointConfigurer.java | 11 ++++---- .../aws2/ec2/AWS2EC2EndpointUriFactory.java | 3 +-- .../apache/camel/component/aws2/ec2/aws2-ec2.json | 6 ++--- .../src/main/docs/aws2-ec2-component.adoc | 10 +++----- .../camel/component/aws2/ec2/AWS2EC2Component.java | 3 --- .../dsl/Aws2Ec2ComponentBuilderFactory.java | 16 ------------ .../dsl/AWS2EC2EndpointBuilderFactory.java | 30 ---------------------- .../modules/ROOT/pages/aws2-ec2-component.adoc | 10 +++----- 10 files changed, 25 insertions(+), 85 deletions(-) diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws2-ec2-component.adoc b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws2-ec2-component.adoc index b4b587e..2408c7d 100644 --- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws2-ec2-component.adoc +++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/aws2-ec2-component.adoc @@ -42,16 +42,15 @@ You can append query options to the URI in the following format, // component options: START -The AWS 2 Elastic Compute Cloud (EC2) component supports 14 options, which are listed below. +The AWS 2 Elastic Compute Cloud (EC2) component supports 13 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 | *accessKey* (producer) | Amazon AWS Access Key | | String -| *amazonEc2Client* (producer) | To use a existing configured AmazonEC2Client as client | | Ec2Client +| *amazonEc2Client* (producer) | *Autowired* To use a existing configured AmazonEC2Client as client | | Ec2Client | *configuration* (producer) | The component configuration | | AWS2EC2Configuration | *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 [...] | *operation* (producer) | *Required* The operation to perform. It can be createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances, createTags or deleteTags. There are 11 enums and the value can be one of: createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances [...] @@ -88,15 +87,14 @@ with the following path and query parameters: |=== -=== Query Parameters (13 parameters): +=== Query Parameters (12 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 | *accessKey* (producer) | Amazon AWS Access Key | | String -| *amazonEc2Client* (producer) | To use a existing configured AmazonEC2Client as client | | Ec2Client +| *amazonEc2Client* (producer) | *Autowired* To use a existing configured AmazonEC2Client as client | | Ec2Client | *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 [...] | *operation* (producer) | *Required* The operation to perform. It can be createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances, createTags or deleteTags. There are 11 enums and the value can be one of: createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances [...] | *pojoRequest* (producer) | If we want to use a POJO request as body or not | false | boolean diff --git a/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2ComponentConfigurer.java b/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2ComponentConfigurer.java index d9ebf63..2281c7f 100644 --- a/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2ComponentConfigurer.java +++ b/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2ComponentConfigurer.java @@ -32,8 +32,6 @@ public class AWS2EC2ComponentConfigurer extends PropertyConfigurerSupport implem case "accessKey": getOrCreateConfiguration(target).setAccessKey(property(camelContext, java.lang.String.class, value)); return true; case "amazonec2client": case "amazonEc2Client": getOrCreateConfiguration(target).setAmazonEc2Client(property(camelContext, software.amazon.awssdk.services.ec2.Ec2Client.class, value)); return true; - case "autodiscoverclient": - case "autoDiscoverClient": getOrCreateConfiguration(target).setAutoDiscoverClient(property(camelContext, boolean.class, value)); return true; case "autowiredenabled": case "autowiredEnabled": target.setAutowiredEnabled(property(camelContext, boolean.class, value)); return true; case "configuration": target.setConfiguration(property(camelContext, org.apache.camel.component.aws2.ec2.AWS2EC2Configuration.class, value)); return true; @@ -58,14 +56,17 @@ public class AWS2EC2ComponentConfigurer extends PropertyConfigurerSupport implem } @Override + public String[] getAutowiredNames() { + return new String[]{"amazonEc2Client"}; + } + + @Override public Class<?> getOptionType(String name, boolean ignoreCase) { switch (ignoreCase ? name.toLowerCase() : name) { case "accesskey": case "accessKey": return java.lang.String.class; case "amazonec2client": case "amazonEc2Client": return software.amazon.awssdk.services.ec2.Ec2Client.class; - case "autodiscoverclient": - case "autoDiscoverClient": return boolean.class; case "autowiredenabled": case "autowiredEnabled": return boolean.class; case "configuration": return org.apache.camel.component.aws2.ec2.AWS2EC2Configuration.class; @@ -97,8 +98,6 @@ public class AWS2EC2ComponentConfigurer extends PropertyConfigurerSupport implem case "accessKey": return getOrCreateConfiguration(target).getAccessKey(); case "amazonec2client": case "amazonEc2Client": return getOrCreateConfiguration(target).getAmazonEc2Client(); - case "autodiscoverclient": - case "autoDiscoverClient": return getOrCreateConfiguration(target).isAutoDiscoverClient(); case "autowiredenabled": case "autowiredEnabled": return target.isAutowiredEnabled(); case "configuration": return target.getConfiguration(); diff --git a/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2EndpointConfigurer.java b/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2EndpointConfigurer.java index fb12736..8b8d3e3 100644 --- a/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2EndpointConfigurer.java +++ b/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2EndpointConfigurer.java @@ -25,8 +25,6 @@ public class AWS2EC2EndpointConfigurer extends PropertyConfigurerSupport impleme case "accessKey": target.getConfiguration().setAccessKey(property(camelContext, java.lang.String.class, value)); return true; case "amazonec2client": case "amazonEc2Client": target.getConfiguration().setAmazonEc2Client(property(camelContext, software.amazon.awssdk.services.ec2.Ec2Client.class, value)); return true; - case "autodiscoverclient": - case "autoDiscoverClient": target.getConfiguration().setAutoDiscoverClient(property(camelContext, boolean.class, value)); return true; case "lazystartproducer": case "lazyStartProducer": target.setLazyStartProducer(property(camelContext, boolean.class, value)); return true; case "operation": target.getConfiguration().setOperation(property(camelContext, org.apache.camel.component.aws2.ec2.AWS2EC2Operations.class, value)); return true; @@ -49,14 +47,17 @@ public class AWS2EC2EndpointConfigurer extends PropertyConfigurerSupport impleme } @Override + public String[] getAutowiredNames() { + return new String[]{"amazonEc2Client"}; + } + + @Override public Class<?> getOptionType(String name, boolean ignoreCase) { switch (ignoreCase ? name.toLowerCase() : name) { case "accesskey": case "accessKey": return java.lang.String.class; case "amazonec2client": case "amazonEc2Client": return software.amazon.awssdk.services.ec2.Ec2Client.class; - case "autodiscoverclient": - case "autoDiscoverClient": return boolean.class; case "lazystartproducer": case "lazyStartProducer": return boolean.class; case "operation": return org.apache.camel.component.aws2.ec2.AWS2EC2Operations.class; @@ -86,8 +87,6 @@ public class AWS2EC2EndpointConfigurer extends PropertyConfigurerSupport impleme case "accessKey": return target.getConfiguration().getAccessKey(); case "amazonec2client": case "amazonEc2Client": return target.getConfiguration().getAmazonEc2Client(); - case "autodiscoverclient": - case "autoDiscoverClient": return target.getConfiguration().isAutoDiscoverClient(); case "lazystartproducer": case "lazyStartProducer": return target.isLazyStartProducer(); case "operation": return target.getConfiguration().getOperation(); diff --git a/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2EndpointUriFactory.java b/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2EndpointUriFactory.java index 2c5c923..e48678c 100644 --- a/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2EndpointUriFactory.java +++ b/components/camel-aws2-ec2/src/generated/java/org/apache/camel/component/aws2/ec2/AWS2EC2EndpointUriFactory.java @@ -20,8 +20,7 @@ public class AWS2EC2EndpointUriFactory extends org.apache.camel.support.componen private static final Set<String> PROPERTY_NAMES; private static final Set<String> SECRET_PROPERTY_NAMES; static { - Set<String> props = new HashSet<>(14); - props.add("autoDiscoverClient"); + Set<String> props = new HashSet<>(13); props.add("proxyProtocol"); props.add("secretKey"); props.add("synchronous"); diff --git a/components/camel-aws2-ec2/src/generated/resources/org/apache/camel/component/aws2/ec2/aws2-ec2.json b/components/camel-aws2-ec2/src/generated/resources/org/apache/camel/component/aws2/ec2/aws2-ec2.json index a91d641..10b3133 100644 --- a/components/camel-aws2-ec2/src/generated/resources/org/apache/camel/component/aws2/ec2/aws2-ec2.json +++ b/components/camel-aws2-ec2/src/generated/resources/org/apache/camel/component/aws2/ec2/aws2-ec2.json @@ -22,9 +22,8 @@ "lenientProperties": false }, "componentProperties": { - "autoDiscoverClient": { "kind": "property", "displayName": "Auto Discover Client", "group": "common", "label": "common", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": true, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client i [...] "accessKey": { "kind": "property", "displayName": "Access Key", "group": "producer", "label": "producer", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": true, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "Amazon AWS Access Key" }, - "amazonEc2Client": { "kind": "property", "displayName": "Amazon Ec2 Client", "group": "producer", "label": "producer", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.ec2.Ec2Client", "deprecated": false, "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "To use a existing configured AmazonEC2Client as client" }, + "amazonEc2Client": { "kind": "property", "displayName": "Amazon Ec2 Client", "group": "producer", "label": "producer", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.ec2.Ec2Client", "deprecated": false, "deprecationNote": "", "autowired": true, "secret": false, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "To use a existing configured AmazonEC2Client as client" }, "configuration": { "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "deprecated": false, "autowired": 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, "autowired": 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 star [...] "operation": { "kind": "property", "displayName": "Operation", "group": "producer", "label": "producer", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws2.ec2.AWS2EC2Operations", "enum": [ "createAndRunInstances", "startInstances", "stopInstances", "terminateInstances", "describeInstances", "describeInstancesStatus", "rebootInstances", "monitorInstances", "unmonitorInstances", "createTags", "deleteTags" ], "deprecated": false, "deprecationNote": "", "au [...] @@ -39,9 +38,8 @@ }, "properties": { "label": { "kind": "path", "displayName": "Label", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "Logical name" }, - "autoDiscoverClient": { "kind": "parameter", "displayName": "Auto Discover Client", "group": "common", "label": "common", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": true, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "Setting the autoDiscoverClient mechanism, if true, the component will look for a client [...] "accessKey": { "kind": "parameter", "displayName": "Access Key", "group": "producer", "label": "producer", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": true, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "Amazon AWS Access Key" }, - "amazonEc2Client": { "kind": "parameter", "displayName": "Amazon Ec2 Client", "group": "producer", "label": "producer", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.ec2.Ec2Client", "deprecated": false, "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "To use a existing configured AmazonEC2Client as client" }, + "amazonEc2Client": { "kind": "parameter", "displayName": "Amazon Ec2 Client", "group": "producer", "label": "producer", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.ec2.Ec2Client", "deprecated": false, "deprecationNote": "", "autowired": true, "secret": false, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "To use a existing configured AmazonEC2Client as client" }, "lazyStartProducer": { "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": 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 sta [...] "operation": { "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "producer", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws2.ec2.AWS2EC2Operations", "enum": [ "createAndRunInstances", "startInstances", "stopInstances", "terminateInstances", "describeInstances", "describeInstancesStatus", "rebootInstances", "monitorInstances", "unmonitorInstances", "createTags", "deleteTags" ], "deprecated": false, "deprecationNote": "", "a [...] "pojoRequest": { "kind": "parameter", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws2.ec2.AWS2EC2Configuration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" }, diff --git a/components/camel-aws2-ec2/src/main/docs/aws2-ec2-component.adoc b/components/camel-aws2-ec2/src/main/docs/aws2-ec2-component.adoc index b4b587e..2408c7d 100644 --- a/components/camel-aws2-ec2/src/main/docs/aws2-ec2-component.adoc +++ b/components/camel-aws2-ec2/src/main/docs/aws2-ec2-component.adoc @@ -42,16 +42,15 @@ You can append query options to the URI in the following format, // component options: START -The AWS 2 Elastic Compute Cloud (EC2) component supports 14 options, which are listed below. +The AWS 2 Elastic Compute Cloud (EC2) component supports 13 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 | *accessKey* (producer) | Amazon AWS Access Key | | String -| *amazonEc2Client* (producer) | To use a existing configured AmazonEC2Client as client | | Ec2Client +| *amazonEc2Client* (producer) | *Autowired* To use a existing configured AmazonEC2Client as client | | Ec2Client | *configuration* (producer) | The component configuration | | AWS2EC2Configuration | *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 [...] | *operation* (producer) | *Required* The operation to perform. It can be createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances, createTags or deleteTags. There are 11 enums and the value can be one of: createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances [...] @@ -88,15 +87,14 @@ with the following path and query parameters: |=== -=== Query Parameters (13 parameters): +=== Query Parameters (12 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 | *accessKey* (producer) | Amazon AWS Access Key | | String -| *amazonEc2Client* (producer) | To use a existing configured AmazonEC2Client as client | | Ec2Client +| *amazonEc2Client* (producer) | *Autowired* To use a existing configured AmazonEC2Client as client | | Ec2Client | *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 [...] | *operation* (producer) | *Required* The operation to perform. It can be createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances, createTags or deleteTags. There are 11 enums and the value can be one of: createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances [...] | *pojoRequest* (producer) | If we want to use a POJO request as body or not | false | boolean diff --git a/components/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java b/components/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java index 83e941b..0139af2 100644 --- a/components/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java +++ b/components/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java @@ -17,17 +17,14 @@ package org.apache.camel.component.aws2.ec2; import java.util.Map; -import java.util.Set; import org.apache.camel.CamelContext; import org.apache.camel.Endpoint; import org.apache.camel.spi.Metadata; import org.apache.camel.spi.annotations.Component; import org.apache.camel.support.DefaultComponent; -import org.apache.camel.util.ObjectHelper; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import software.amazon.awssdk.services.ec2.Ec2Client; /** * For working with Amazon's Elastic Compute Cloud (EC2) SDK v2. diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2Ec2ComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2Ec2ComponentBuilderFactory.java index e79ea90..7e294db 100644 --- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2Ec2ComponentBuilderFactory.java +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2Ec2ComponentBuilderFactory.java @@ -49,21 +49,6 @@ public interface Aws2Ec2ComponentBuilderFactory { extends ComponentBuilder<AWS2EC2Component> { /** - * 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 Aws2Ec2ComponentBuilder autoDiscoverClient( - boolean autoDiscoverClient) { - doSetProperty("autoDiscoverClient", autoDiscoverClient); - return this; - } - /** * Amazon AWS Access Key. * * The option is a: <code>java.lang.String</code> type. @@ -268,7 +253,6 @@ public interface Aws2Ec2ComponentBuilderFactory { String name, Object value) { switch (name) { - case "autoDiscoverClient": getOrCreateConfiguration((AWS2EC2Component) component).setAutoDiscoverClient((boolean) value); return true; case "accessKey": getOrCreateConfiguration((AWS2EC2Component) component).setAccessKey((java.lang.String) value); return true; case "amazonEc2Client": getOrCreateConfiguration((AWS2EC2Component) component).setAmazonEc2Client((software.amazon.awssdk.services.ec2.Ec2Client) value); return true; case "configuration": ((AWS2EC2Component) component).setConfiguration((org.apache.camel.component.aws2.ec2.AWS2EC2Configuration) value); return true; diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/AWS2EC2EndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/AWS2EC2EndpointBuilderFactory.java index d04dde5..20b2495 100644 --- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/AWS2EC2EndpointBuilderFactory.java +++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/AWS2EC2EndpointBuilderFactory.java @@ -38,36 +38,6 @@ public interface AWS2EC2EndpointBuilderFactory { return (AdvancedAWS2EC2EndpointBuilder) 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 AWS2EC2EndpointBuilder 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 AWS2EC2EndpointBuilder autoDiscoverClient( - String autoDiscoverClient) { - doSetProperty("autoDiscoverClient", autoDiscoverClient); - return this; - } - /** * Amazon AWS Access Key. * * The option is a: <code>java.lang.String</code> type. diff --git a/docs/components/modules/ROOT/pages/aws2-ec2-component.adoc b/docs/components/modules/ROOT/pages/aws2-ec2-component.adoc index 4c32759..412a054 100644 --- a/docs/components/modules/ROOT/pages/aws2-ec2-component.adoc +++ b/docs/components/modules/ROOT/pages/aws2-ec2-component.adoc @@ -44,16 +44,15 @@ You can append query options to the URI in the following format, // component options: START -The AWS 2 Elastic Compute Cloud (EC2) component supports 14 options, which are listed below. +The AWS 2 Elastic Compute Cloud (EC2) component supports 13 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 | *accessKey* (producer) | Amazon AWS Access Key | | String -| *amazonEc2Client* (producer) | To use a existing configured AmazonEC2Client as client | | Ec2Client +| *amazonEc2Client* (producer) | *Autowired* To use a existing configured AmazonEC2Client as client | | Ec2Client | *configuration* (producer) | The component configuration | | AWS2EC2Configuration | *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 [...] | *operation* (producer) | *Required* The operation to perform. It can be createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances, createTags or deleteTags. There are 11 enums and the value can be one of: createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances [...] @@ -90,15 +89,14 @@ with the following path and query parameters: |=== -=== Query Parameters (13 parameters): +=== Query Parameters (12 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 | *accessKey* (producer) | Amazon AWS Access Key | | String -| *amazonEc2Client* (producer) | To use a existing configured AmazonEC2Client as client | | Ec2Client +| *amazonEc2Client* (producer) | *Autowired* To use a existing configured AmazonEC2Client as client | | Ec2Client | *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 [...] | *operation* (producer) | *Required* The operation to perform. It can be createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances, createTags or deleteTags. There are 11 enums and the value can be one of: createAndRunInstances, startInstances, stopInstances, terminateInstances, describeInstances, describeInstancesStatus, rebootInstances, monitorInstances, unmonitorInstances [...] | *pojoRequest* (producer) | If we want to use a POJO request as body or not | false | boolean
