This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/master by this push: new 3f51e25 CAMEL-14622: Component options use @Metadata to markup the options 3f51e25 is described below commit 3f51e25a86bec14bbdd92c68a04a56d362d86c6f Author: Claus Ibsen <claus.ib...@gmail.com> AuthorDate: Tue Jun 16 14:55:30 2020 +0200 CAMEL-14622: Component options use @Metadata to markup the options --- .../src/main/docs/ignite-cache-component.adoc | 6 ++-- .../src/main/docs/ignite-compute-component.adoc | 6 ++-- .../src/main/docs/ignite-events-component.adoc | 6 ++-- .../src/main/docs/ignite-idgen-component.adoc | 6 ++-- .../src/main/docs/ignite-messaging-component.adoc | 6 ++-- .../src/main/docs/ignite-queue-component.adoc | 6 ++-- .../src/main/docs/ignite-set-component.adoc | 6 ++-- .../component/ignite/AbstractIgniteComponent.java | 32 ++++++---------------- .../apache/camel/component/influxdb/influxdb.json | 2 +- .../component/influxdb/InfluxDbComponent.java | 2 ++ .../org/apache/camel/component/jcache/jcache.json | 10 +++---- .../camel/component/jcache/JCacheComponent.java | 6 ++++ .../org/apache/camel/component/jdbc/jdbc.json | 2 +- .../apache/camel/component/jdbc/JdbcComponent.java | 4 ++- .../dsl/IgniteCacheComponentBuilderFactory.java | 7 +++-- .../dsl/IgniteComputeComponentBuilderFactory.java | 7 +++-- .../dsl/IgniteEventsComponentBuilderFactory.java | 7 +++-- .../dsl/IgniteIdgenComponentBuilderFactory.java | 7 +++-- .../IgniteMessagingComponentBuilderFactory.java | 7 +++-- .../dsl/IgniteQueueComponentBuilderFactory.java | 7 +++-- .../dsl/IgniteSetComponentBuilderFactory.java | 7 +++-- 21 files changed, 76 insertions(+), 73 deletions(-) diff --git a/components/camel-ignite/src/main/docs/ignite-cache-component.adoc b/components/camel-ignite/src/main/docs/ignite-cache-component.adoc index 683dd64..bae9cca 100644 --- a/components/camel-ignite/src/main/docs/ignite-cache-component.adoc +++ b/components/camel-ignite/src/main/docs/ignite-cache-component.adoc @@ -30,9 +30,9 @@ The Ignite Cache component supports 6 options, which are listed below. [width="100%",cols="2,5,^1,2",options="header"] |=== | Name | Description | Default | Type -| *configurationResource* (common) | Resource from where to load configuration. | | Object -| *ignite* (common) | Ignite instance. | | Ignite -| *igniteConfiguration* (common) | Ignite configuration. | | IgniteConfiguration +| *configurationResource* (common) | The resource from where to load the configuration. It can be a: URL, String or InputStream type. | | Object +| *ignite* (common) | To use an existing Ignite instance. | | Ignite +| *igniteConfiguration* (common) | Allows the user to set a programmatic ignite configuration. | | IgniteConfiguration | *bridgeErrorHandler* (consumer) | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. | false | 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 [...] | *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean diff --git a/components/camel-ignite/src/main/docs/ignite-compute-component.adoc b/components/camel-ignite/src/main/docs/ignite-compute-component.adoc index c509bc8..da735a0 100644 --- a/components/camel-ignite/src/main/docs/ignite-compute-component.adoc +++ b/components/camel-ignite/src/main/docs/ignite-compute-component.adoc @@ -31,9 +31,9 @@ The Ignite Compute component supports 5 options, which are listed below. [width="100%",cols="2,5,^1,2",options="header"] |=== | Name | Description | Default | Type -| *configurationResource* (producer) | Resource from where to load configuration. | | Object -| *ignite* (producer) | Ignite instance. | | Ignite -| *igniteConfiguration* (producer) | Ignite configuration. | | IgniteConfiguration +| *configurationResource* (producer) | The resource from where to load the configuration. It can be a: URL, String or InputStream type. | | Object +| *ignite* (producer) | To use an existing Ignite instance. | | Ignite +| *igniteConfiguration* (producer) | Allows the user to set a programmatic ignite configuration. | | IgniteConfiguration | *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 [...] | *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean |=== diff --git a/components/camel-ignite/src/main/docs/ignite-events-component.adoc b/components/camel-ignite/src/main/docs/ignite-events-component.adoc index 9e90b16..4d60125 100644 --- a/components/camel-ignite/src/main/docs/ignite-events-component.adoc +++ b/components/camel-ignite/src/main/docs/ignite-events-component.adoc @@ -29,9 +29,9 @@ The Ignite Events component supports 5 options, which are listed below. |=== | Name | Description | Default | Type | *bridgeErrorHandler* (consumer) | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. | false | boolean -| *configurationResource* (consumer) | Resource from where to load configuration. | | Object -| *ignite* (consumer) | Ignite instance. | | Ignite -| *igniteConfiguration* (consumer) | Ignite configuration. | | IgniteConfiguration +| *configurationResource* (consumer) | The resource from where to load the configuration. It can be a: URL, String or InputStream type. | | Object +| *ignite* (consumer) | To use an existing Ignite instance. | | Ignite +| *igniteConfiguration* (consumer) | Allows the user to set a programmatic ignite configuration. | | IgniteConfiguration | *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean |=== // component options: END diff --git a/components/camel-ignite/src/main/docs/ignite-idgen-component.adoc b/components/camel-ignite/src/main/docs/ignite-idgen-component.adoc index 113f9c6..01770fb 100644 --- a/components/camel-ignite/src/main/docs/ignite-idgen-component.adoc +++ b/components/camel-ignite/src/main/docs/ignite-idgen-component.adoc @@ -27,9 +27,9 @@ The Ignite ID Generator component supports 5 options, which are listed below. [width="100%",cols="2,5,^1,2",options="header"] |=== | Name | Description | Default | Type -| *configurationResource* (producer) | Resource from where to load configuration. | | Object -| *ignite* (producer) | Ignite instance. | | Ignite -| *igniteConfiguration* (producer) | Ignite configuration. | | IgniteConfiguration +| *configurationResource* (producer) | The resource from where to load the configuration. It can be a: URL, String or InputStream type. | | Object +| *ignite* (producer) | To use an existing Ignite instance. | | Ignite +| *igniteConfiguration* (producer) | Allows the user to set a programmatic ignite configuration. | | IgniteConfiguration | *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 [...] | *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean |=== diff --git a/components/camel-ignite/src/main/docs/ignite-messaging-component.adoc b/components/camel-ignite/src/main/docs/ignite-messaging-component.adoc index 5f62e7c..35ff694 100644 --- a/components/camel-ignite/src/main/docs/ignite-messaging-component.adoc +++ b/components/camel-ignite/src/main/docs/ignite-messaging-component.adoc @@ -27,9 +27,9 @@ The Ignite Messaging component supports 6 options, which are listed below. [width="100%",cols="2,5,^1,2",options="header"] |=== | Name | Description | Default | Type -| *configurationResource* (common) | Resource from where to load configuration. | | Object -| *ignite* (common) | Ignite instance. | | Ignite -| *igniteConfiguration* (common) | Ignite configuration. | | IgniteConfiguration +| *configurationResource* (common) | The resource from where to load the configuration. It can be a: URL, String or InputStream type. | | Object +| *ignite* (common) | To use an existing Ignite instance. | | Ignite +| *igniteConfiguration* (common) | Allows the user to set a programmatic ignite configuration. | | IgniteConfiguration | *bridgeErrorHandler* (consumer) | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. | false | 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 [...] | *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean diff --git a/components/camel-ignite/src/main/docs/ignite-queue-component.adoc b/components/camel-ignite/src/main/docs/ignite-queue-component.adoc index c8d7dbf..4eb3e22 100644 --- a/components/camel-ignite/src/main/docs/ignite-queue-component.adoc +++ b/components/camel-ignite/src/main/docs/ignite-queue-component.adoc @@ -27,9 +27,9 @@ The Ignite Queues component supports 5 options, which are listed below. [width="100%",cols="2,5,^1,2",options="header"] |=== | Name | Description | Default | Type -| *configurationResource* (producer) | Resource from where to load configuration. | | Object -| *ignite* (producer) | Ignite instance. | | Ignite -| *igniteConfiguration* (producer) | Ignite configuration. | | IgniteConfiguration +| *configurationResource* (producer) | The resource from where to load the configuration. It can be a: URL, String or InputStream type. | | Object +| *ignite* (producer) | To use an existing Ignite instance. | | Ignite +| *igniteConfiguration* (producer) | Allows the user to set a programmatic ignite configuration. | | IgniteConfiguration | *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 [...] | *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean |=== diff --git a/components/camel-ignite/src/main/docs/ignite-set-component.adoc b/components/camel-ignite/src/main/docs/ignite-set-component.adoc index 125f47a..00e8e9f 100644 --- a/components/camel-ignite/src/main/docs/ignite-set-component.adoc +++ b/components/camel-ignite/src/main/docs/ignite-set-component.adoc @@ -27,9 +27,9 @@ The Ignite Sets component supports 5 options, which are listed below. [width="100%",cols="2,5,^1,2",options="header"] |=== | Name | Description | Default | Type -| *configurationResource* (producer) | Resource from where to load configuration. | | Object -| *ignite* (producer) | Ignite instance. | | Ignite -| *igniteConfiguration* (producer) | Ignite configuration. | | IgniteConfiguration +| *configurationResource* (producer) | The resource from where to load the configuration. It can be a: URL, String or InputStream type. | | Object +| *ignite* (producer) | To use an existing Ignite instance. | | Ignite +| *igniteConfiguration* (producer) | Allows the user to set a programmatic ignite configuration. | | IgniteConfiguration | *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 [...] | *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean |=== diff --git a/components/camel-ignite/src/main/java/org/apache/camel/component/ignite/AbstractIgniteComponent.java b/components/camel-ignite/src/main/java/org/apache/camel/component/ignite/AbstractIgniteComponent.java index 161b6be..49c514d 100644 --- a/components/camel-ignite/src/main/java/org/apache/camel/component/ignite/AbstractIgniteComponent.java +++ b/components/camel-ignite/src/main/java/org/apache/camel/component/ignite/AbstractIgniteComponent.java @@ -17,9 +17,9 @@ package org.apache.camel.component.ignite; import java.io.InputStream; -import java.net.URI; import java.net.URL; +import org.apache.camel.spi.Metadata; import org.apache.camel.support.DefaultComponent; import org.apache.ignite.Ignite; import org.apache.ignite.Ignition; @@ -46,18 +46,15 @@ public abstract class AbstractIgniteComponent extends DefaultComponent { USER_MANAGED, COMPONENT_MANAGED } - /** Ignite configuration. */ - private IgniteConfiguration igniteConfiguration; + private IgniteLifecycleMode lifecycleMode = IgniteLifecycleMode.COMPONENT_MANAGED; - /** Resource from where to load configuration. */ + @Metadata + private IgniteConfiguration igniteConfiguration; + @Metadata private Object configurationResource; - - /** Ignite instance. */ + @Metadata private Ignite ignite; - /** How the Ignite lifecycle is managed. */ - private IgniteLifecycleMode lifecycleMode = IgniteLifecycleMode.COMPONENT_MANAGED; - @Override protected void doStart() throws Exception { super.doStart(); @@ -97,46 +94,35 @@ public abstract class AbstractIgniteComponent extends DefaultComponent { } } - /** - * Returns the {@link Ignite} instance. - */ public Ignite getIgnite() { return ignite; } /** - * Sets the {@link Ignite} instance. + * To use an existing Ignite instance. */ public void setIgnite(Ignite ignite) { this.ignite = ignite; lifecycleMode = IgniteLifecycleMode.USER_MANAGED; } - /** - * Gets the resource from where to load the configuration. It can be a: {@link URI}, {@link String} (URI) - * or an {@link InputStream}. - */ public Object getConfigurationResource() { return configurationResource; } /** - * Sets the resource from where to load the configuration. It can be a: {@link URI}, {@link String} (URI) - * or an {@link InputStream}. + * The resource from where to load the configuration. It can be a: URL, String or InputStream type. */ public void setConfigurationResource(Object configurationResource) { this.configurationResource = configurationResource; } - /** - * Gets the {@link IgniteConfiguration} if the user set it explicitly. - */ public IgniteConfiguration getIgniteConfiguration() { return igniteConfiguration; } /** - * Allows the user to set a programmatic {@link IgniteConfiguration}. + * Allows the user to set a programmatic ignite configuration. */ public void setIgniteConfiguration(IgniteConfiguration igniteConfiguration) { this.igniteConfiguration = igniteConfiguration; diff --git a/components/camel-influxdb/src/generated/resources/org/apache/camel/component/influxdb/influxdb.json b/components/camel-influxdb/src/generated/resources/org/apache/camel/component/influxdb/influxdb.json index b2c6447..ae12539 100644 --- a/components/camel-influxdb/src/generated/resources/org/apache/camel/component/influxdb/influxdb.json +++ b/components/camel-influxdb/src/generated/resources/org/apache/camel/component/influxdb/influxdb.json @@ -21,7 +21,7 @@ "lenientProperties": false }, "componentProperties": { - "influxDB": { "kind": "property", "displayName": "Influx DB", "group": "producer", "required": false, "type": "object", "javaType": "org.influxdb.InfluxDB", "deprecated": false, "secret": false, "description": "The shared Influx DB to use for all endpoints" }, + "influxDB": { "kind": "property", "displayName": "Influx DB", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.influxdb.InfluxDB", "deprecated": false, "secret": false, "description": "The shared Influx DB to use for all endpoints" }, "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 [...] "basicPropertyBinding": { "kind": "property", "displayName": "Basic Property Binding", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities" } }, diff --git a/components/camel-influxdb/src/main/java/org/apache/camel/component/influxdb/InfluxDbComponent.java b/components/camel-influxdb/src/main/java/org/apache/camel/component/influxdb/InfluxDbComponent.java index f137a15..937d983 100644 --- a/components/camel-influxdb/src/main/java/org/apache/camel/component/influxdb/InfluxDbComponent.java +++ b/components/camel-influxdb/src/main/java/org/apache/camel/component/influxdb/InfluxDbComponent.java @@ -19,6 +19,7 @@ package org.apache.camel.component.influxdb; import java.util.Map; import org.apache.camel.Endpoint; +import org.apache.camel.spi.Metadata; import org.apache.camel.spi.annotations.Component; import org.apache.camel.support.CamelContextHelper; import org.apache.camel.support.DefaultComponent; @@ -27,6 +28,7 @@ import org.influxdb.InfluxDB; @Component("influxdb") public class InfluxDbComponent extends DefaultComponent { + @Metadata private InfluxDB influxDB; public InfluxDbComponent() { diff --git a/components/camel-jcache/src/generated/resources/org/apache/camel/component/jcache/jcache.json b/components/camel-jcache/src/generated/resources/org/apache/camel/component/jcache/jcache.json index fac390e..07fd782 100644 --- a/components/camel-jcache/src/generated/resources/org/apache/camel/component/jcache/jcache.json +++ b/components/camel-jcache/src/generated/resources/org/apache/camel/component/jcache/jcache.json @@ -21,11 +21,11 @@ "lenientProperties": false }, "componentProperties": { - "cacheConfiguration": { "kind": "property", "displayName": "Cache Configuration", "group": "common", "required": false, "type": "object", "javaType": "javax.cache.configuration.Configuration", "deprecated": false, "secret": false, "description": "A Configuration for the Cache" }, - "cacheConfigurationProperties": { "kind": "property", "displayName": "Cache Configuration Properties", "group": "common", "required": false, "type": "object", "javaType": "java.util.Map", "deprecated": false, "secret": false, "description": "Properties to configure jcache" }, - "cacheConfigurationPropertiesRef": { "kind": "property", "displayName": "Cache Configuration Properties Ref", "group": "common", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "References to an existing Properties or Map to lookup in the registry to use for configuring jcache." }, - "cachingProvider": { "kind": "property", "displayName": "Caching Provider", "group": "common", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "The fully qualified class name of the javax.cache.spi.CachingProvider" }, - "configurationUri": { "kind": "property", "displayName": "Configuration Uri", "group": "common", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "An implementation specific URI for the CacheManager" }, + "cacheConfiguration": { "kind": "property", "displayName": "Cache Configuration", "group": "common", "label": "", "required": false, "type": "object", "javaType": "javax.cache.configuration.Configuration", "deprecated": false, "secret": false, "description": "A Configuration for the Cache" }, + "cacheConfigurationProperties": { "kind": "property", "displayName": "Cache Configuration Properties", "group": "common", "label": "", "required": false, "type": "object", "javaType": "java.util.Map", "deprecated": false, "secret": false, "description": "Properties to configure jcache" }, + "cacheConfigurationPropertiesRef": { "kind": "property", "displayName": "Cache Configuration Properties Ref", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "References to an existing Properties or Map to lookup in the registry to use for configuring jcache." }, + "cachingProvider": { "kind": "property", "displayName": "Caching Provider", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "The fully qualified class name of the javax.cache.spi.CachingProvider" }, + "configurationUri": { "kind": "property", "displayName": "Configuration Uri", "group": "common", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "An implementation specific URI for the CacheManager" }, "bridgeErrorHandler": { "kind": "property", "displayName": "Bridge Error Handler", "group": "consumer", "label": "consumer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by [...] "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 [...] "basicPropertyBinding": { "kind": "property", "displayName": "Basic Property Binding", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities" } diff --git a/components/camel-jcache/src/main/java/org/apache/camel/component/jcache/JCacheComponent.java b/components/camel-jcache/src/main/java/org/apache/camel/component/jcache/JCacheComponent.java index a88a1b6..9701468 100644 --- a/components/camel-jcache/src/main/java/org/apache/camel/component/jcache/JCacheComponent.java +++ b/components/camel-jcache/src/main/java/org/apache/camel/component/jcache/JCacheComponent.java @@ -25,6 +25,7 @@ import javax.cache.configuration.Configuration; 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.CamelContextHelper; import org.apache.camel.support.DefaultComponent; @@ -32,10 +33,15 @@ import org.apache.camel.support.DefaultComponent; @Component("jcache") public class JCacheComponent extends DefaultComponent { + @Metadata private String cachingProvider; + @Metadata private Configuration cacheConfiguration; + @Metadata private String cacheConfigurationPropertiesRef; + @Metadata private Map cacheConfigurationProperties; + @Metadata private String configurationUri; public JCacheComponent() { diff --git a/components/camel-jdbc/src/generated/resources/org/apache/camel/component/jdbc/jdbc.json b/components/camel-jdbc/src/generated/resources/org/apache/camel/component/jdbc/jdbc.json index 33c4b5a..0a6abea 100644 --- a/components/camel-jdbc/src/generated/resources/org/apache/camel/component/jdbc/jdbc.json +++ b/components/camel-jdbc/src/generated/resources/org/apache/camel/component/jdbc/jdbc.json @@ -21,7 +21,7 @@ "lenientProperties": false }, "componentProperties": { - "dataSource": { "kind": "property", "displayName": "Data Source", "group": "producer", "required": false, "type": "object", "javaType": "javax.sql.DataSource", "deprecated": false, "secret": false, "description": "To use the DataSource instance instead of looking up the data source by name from the registry." }, + "dataSource": { "kind": "property", "displayName": "Data Source", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "javax.sql.DataSource", "deprecated": false, "secret": false, "description": "To use the DataSource instance instead of looking up the data source by name from the registry." }, "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 [...] "basicPropertyBinding": { "kind": "property", "displayName": "Basic Property Binding", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities" } }, diff --git a/components/camel-jdbc/src/main/java/org/apache/camel/component/jdbc/JdbcComponent.java b/components/camel-jdbc/src/main/java/org/apache/camel/component/jdbc/JdbcComponent.java index a2b9550..a3fd279 100644 --- a/components/camel-jdbc/src/main/java/org/apache/camel/component/jdbc/JdbcComponent.java +++ b/components/camel-jdbc/src/main/java/org/apache/camel/component/jdbc/JdbcComponent.java @@ -23,6 +23,7 @@ import javax.sql.DataSource; import org.apache.camel.Endpoint; import org.apache.camel.NoSuchBeanException; +import org.apache.camel.spi.Metadata; import org.apache.camel.spi.annotations.Component; import org.apache.camel.support.CamelContextHelper; import org.apache.camel.support.DefaultComponent; @@ -35,6 +36,7 @@ public class JdbcComponent extends DefaultComponent { private static final Logger LOG = LoggerFactory.getLogger(JdbcComponent.class); + @Metadata private DataSource dataSource; @Override @@ -56,7 +58,7 @@ public class JdbcComponent extends DefaultComponent { if (dataSources.size() > 1) { throw new IllegalArgumentException("Multiple DataSources found in the registry and no explicit configuration provided"); } else if (dataSources.size() == 1) { - target = dataSources.stream().findFirst().orElse(null); + target = dataSources.iterator().next(); } if (target == null) { throw new IllegalArgumentException("No default DataSource found in the registry"); diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteCacheComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteCacheComponentBuilderFactory.java index 20119cb..7935703 100644 --- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteCacheComponentBuilderFactory.java +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteCacheComponentBuilderFactory.java @@ -51,7 +51,8 @@ public interface IgniteCacheComponentBuilderFactory { extends ComponentBuilder<IgniteCacheComponent> { /** - * Resource from where to load configuration. + * The resource from where to load the configuration. It can be a: URL, + * String or InputStream type. * * The option is a: <code>java.lang.Object</code> type. * @@ -63,7 +64,7 @@ public interface IgniteCacheComponentBuilderFactory { return this; } /** - * Ignite instance. + * To use an existing Ignite instance. * * The option is a: <code>org.apache.ignite.Ignite</code> type. * @@ -75,7 +76,7 @@ public interface IgniteCacheComponentBuilderFactory { return this; } /** - * Ignite configuration. + * Allows the user to set a programmatic ignite configuration. * * The option is a: * <code>org.apache.ignite.configuration.IgniteConfiguration</code> diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteComputeComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteComputeComponentBuilderFactory.java index 090cf34..19dfa9e 100644 --- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteComputeComponentBuilderFactory.java +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteComputeComponentBuilderFactory.java @@ -49,7 +49,8 @@ public interface IgniteComputeComponentBuilderFactory { extends ComponentBuilder<IgniteComputeComponent> { /** - * Resource from where to load configuration. + * The resource from where to load the configuration. It can be a: URL, + * String or InputStream type. * * The option is a: <code>java.lang.Object</code> type. * @@ -61,7 +62,7 @@ public interface IgniteComputeComponentBuilderFactory { return this; } /** - * Ignite instance. + * To use an existing Ignite instance. * * The option is a: <code>org.apache.ignite.Ignite</code> type. * @@ -73,7 +74,7 @@ public interface IgniteComputeComponentBuilderFactory { return this; } /** - * Ignite configuration. + * Allows the user to set a programmatic ignite configuration. * * The option is a: * <code>org.apache.ignite.configuration.IgniteConfiguration</code> diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteEventsComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteEventsComponentBuilderFactory.java index d773d6a..9eb849f 100644 --- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteEventsComponentBuilderFactory.java +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteEventsComponentBuilderFactory.java @@ -68,7 +68,8 @@ public interface IgniteEventsComponentBuilderFactory { return this; } /** - * Resource from where to load configuration. + * The resource from where to load the configuration. It can be a: URL, + * String or InputStream type. * * The option is a: <code>java.lang.Object</code> type. * @@ -80,7 +81,7 @@ public interface IgniteEventsComponentBuilderFactory { return this; } /** - * Ignite instance. + * To use an existing Ignite instance. * * The option is a: <code>org.apache.ignite.Ignite</code> type. * @@ -92,7 +93,7 @@ public interface IgniteEventsComponentBuilderFactory { return this; } /** - * Ignite configuration. + * Allows the user to set a programmatic ignite configuration. * * The option is a: * <code>org.apache.ignite.configuration.IgniteConfiguration</code> diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteIdgenComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteIdgenComponentBuilderFactory.java index 5c1fb69..5f86e91 100644 --- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteIdgenComponentBuilderFactory.java +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteIdgenComponentBuilderFactory.java @@ -49,7 +49,8 @@ public interface IgniteIdgenComponentBuilderFactory { extends ComponentBuilder<IgniteIdGenComponent> { /** - * Resource from where to load configuration. + * The resource from where to load the configuration. It can be a: URL, + * String or InputStream type. * * The option is a: <code>java.lang.Object</code> type. * @@ -61,7 +62,7 @@ public interface IgniteIdgenComponentBuilderFactory { return this; } /** - * Ignite instance. + * To use an existing Ignite instance. * * The option is a: <code>org.apache.ignite.Ignite</code> type. * @@ -73,7 +74,7 @@ public interface IgniteIdgenComponentBuilderFactory { return this; } /** - * Ignite configuration. + * Allows the user to set a programmatic ignite configuration. * * The option is a: * <code>org.apache.ignite.configuration.IgniteConfiguration</code> diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteMessagingComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteMessagingComponentBuilderFactory.java index 3d11276..ed60f1f 100644 --- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteMessagingComponentBuilderFactory.java +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteMessagingComponentBuilderFactory.java @@ -49,7 +49,8 @@ public interface IgniteMessagingComponentBuilderFactory { extends ComponentBuilder<IgniteMessagingComponent> { /** - * Resource from where to load configuration. + * The resource from where to load the configuration. It can be a: URL, + * String or InputStream type. * * The option is a: <code>java.lang.Object</code> type. * @@ -61,7 +62,7 @@ public interface IgniteMessagingComponentBuilderFactory { return this; } /** - * Ignite instance. + * To use an existing Ignite instance. * * The option is a: <code>org.apache.ignite.Ignite</code> type. * @@ -73,7 +74,7 @@ public interface IgniteMessagingComponentBuilderFactory { return this; } /** - * Ignite configuration. + * Allows the user to set a programmatic ignite configuration. * * The option is a: * <code>org.apache.ignite.configuration.IgniteConfiguration</code> diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteQueueComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteQueueComponentBuilderFactory.java index f016525..e346913 100644 --- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteQueueComponentBuilderFactory.java +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteQueueComponentBuilderFactory.java @@ -49,7 +49,8 @@ public interface IgniteQueueComponentBuilderFactory { extends ComponentBuilder<IgniteQueueComponent> { /** - * Resource from where to load configuration. + * The resource from where to load the configuration. It can be a: URL, + * String or InputStream type. * * The option is a: <code>java.lang.Object</code> type. * @@ -61,7 +62,7 @@ public interface IgniteQueueComponentBuilderFactory { return this; } /** - * Ignite instance. + * To use an existing Ignite instance. * * The option is a: <code>org.apache.ignite.Ignite</code> type. * @@ -73,7 +74,7 @@ public interface IgniteQueueComponentBuilderFactory { return this; } /** - * Ignite configuration. + * Allows the user to set a programmatic ignite configuration. * * The option is a: * <code>org.apache.ignite.configuration.IgniteConfiguration</code> diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteSetComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteSetComponentBuilderFactory.java index e5917ce..0dc544a 100644 --- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteSetComponentBuilderFactory.java +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/IgniteSetComponentBuilderFactory.java @@ -49,7 +49,8 @@ public interface IgniteSetComponentBuilderFactory { extends ComponentBuilder<IgniteSetComponent> { /** - * Resource from where to load configuration. + * The resource from where to load the configuration. It can be a: URL, + * String or InputStream type. * * The option is a: <code>java.lang.Object</code> type. * @@ -61,7 +62,7 @@ public interface IgniteSetComponentBuilderFactory { return this; } /** - * Ignite instance. + * To use an existing Ignite instance. * * The option is a: <code>org.apache.ignite.Ignite</code> type. * @@ -72,7 +73,7 @@ public interface IgniteSetComponentBuilderFactory { return this; } /** - * Ignite configuration. + * Allows the user to set a programmatic ignite configuration. * * The option is a: * <code>org.apache.ignite.configuration.IgniteConfiguration</code>