This is an automated email from the ASF dual-hosted git repository. acosentino pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel-kafka-connector.git
The following commit(s) were added to refs/heads/main by this push: new 08e0cd6 [create-pull-request] automated change 08e0cd6 is described below commit 08e0cd66fd6f5b77f8c38d1fcd300c4da9131fc3 Author: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> AuthorDate: Wed May 12 04:17:46 2021 +0000 [create-pull-request] automated change --- .../resources/connectors/camel-kamelet-sink.json | 7 + .../resources/connectors/camel-kamelet-source.json | 7 + .../resources/descriptors/connectors.properties | 2 + .../generated/resources/camel-kamelet-sink.json | 7 + .../generated/resources/camel-kamelet-source.json | 7 + .../docs/camel-kamelet-kafka-sink-connector.adoc | 3 +- .../docs/camel-kamelet-kafka-source-connector.adoc | 3 +- .../kamelet/CamelKameletSinkConnectorConfig.java | 4 + .../kamelet/CamelKameletSourceConnectorConfig.java | 4 + .../camel-kamelet-reify-kafka-connector/pom.xml | 139 ++++++++++++++ .../descriptors/connector-sink.properties | 1 + .../descriptors/connector-source.properties | 1 + .../resources/camel-kamelet-reify-sink.json | 40 ++++ .../resources/camel-kamelet-reify-source.json | 42 ++--- .../src/main/assembly/package.xml | 56 ++++++ .../camel-kamelet-reify-kafka-sink-connector.adoc | 59 ++++++ ...camel-kamelet-reify-kafka-source-connector.adoc | 61 +++++++ .../CamelKameletreifySinkConnector.properties | 33 ++++ .../CamelKameletreifySourceConnector.properties | 33 ++++ .../CamelKameletreifySinkConnector.java | 35 ++++ .../CamelKameletreifySinkConnectorConfig.java | 60 ++++++ .../kameletreify/CamelKameletreifySinkTask.java | 39 ++++ .../CamelKameletreifySourceConnector.java | 35 ++++ .../CamelKameletreifySourceConnectorConfig.java | 69 +++++++ .../kameletreify/CamelKameletreifySourceTask.java | 39 ++++ .../src/main/resources/META-INF/LICENSE.txt | 203 +++++++++++++++++++++ .../src/main/resources/META-INF/NOTICE.txt | 11 ++ connectors/pom.xml | 1 + docs/modules/ROOT/nav.adoc | 3 + docs/modules/ROOT/pages/connectors.adoc | 3 +- .../camel-kamelet-kafka-sink-connector.adoc | 3 +- .../camel-kamelet-kafka-source-connector.adoc | 3 +- .../camel-kamelet-reify-kafka-sink-connector.adoc | 59 ++++++ ...camel-kamelet-reify-kafka-source-connector.adoc | 61 +++++++ 34 files changed, 1098 insertions(+), 35 deletions(-) diff --git a/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-sink.json b/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-sink.json index ffdee48..397200d 100644 --- a/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-sink.json +++ b/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-sink.json @@ -49,6 +49,13 @@ "priority": "MEDIUM", "required": "false" }, + "camel.component.kamelet.location": { + "name": "camel.component.kamelet.location", + "description": "The location of the Kamelets on the file system.", + "defaultValue": "\"classpath:\/kamelets\"", + "priority": "MEDIUM", + "required": "false" + }, "camel.component.kamelet.routeProperties": { "name": "camel.component.kamelet.routeProperties", "description": "Set route local parameters.", diff --git a/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-source.json b/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-source.json index 4322644..efc4e01 100644 --- a/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-source.json +++ b/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-source.json @@ -45,6 +45,13 @@ "InOptionalOut" ] }, + "camel.component.kamelet.location": { + "name": "camel.component.kamelet.location", + "description": "The location of the Kamelets on the file system.", + "defaultValue": "\"classpath:\/kamelets\"", + "priority": "MEDIUM", + "required": "false" + }, "camel.component.kamelet.routeProperties": { "name": "camel.component.kamelet.routeProperties", "description": "Set route local parameters.", diff --git a/camel-kafka-connector-catalog/src/generated/resources/descriptors/connectors.properties b/camel-kafka-connector-catalog/src/generated/resources/descriptors/connectors.properties index 1de74e1..1fe725d 100644 --- a/camel-kafka-connector-catalog/src/generated/resources/descriptors/connectors.properties +++ b/camel-kafka-connector-catalog/src/generated/resources/descriptors/connectors.properties @@ -274,6 +274,8 @@ camel-kafka-source camel-kafka-sink camel-kamelet-source camel-kamelet-sink +camel-kamelet-reify-source +camel-kamelet-reify-sink camel-kubernetes-config-maps-sink camel-kubernetes-custom-resources-source camel-kubernetes-custom-resources-sink diff --git a/connectors/camel-kamelet-kafka-connector/src/generated/resources/camel-kamelet-sink.json b/connectors/camel-kamelet-kafka-connector/src/generated/resources/camel-kamelet-sink.json index ffdee48..397200d 100644 --- a/connectors/camel-kamelet-kafka-connector/src/generated/resources/camel-kamelet-sink.json +++ b/connectors/camel-kamelet-kafka-connector/src/generated/resources/camel-kamelet-sink.json @@ -49,6 +49,13 @@ "priority": "MEDIUM", "required": "false" }, + "camel.component.kamelet.location": { + "name": "camel.component.kamelet.location", + "description": "The location of the Kamelets on the file system.", + "defaultValue": "\"classpath:\/kamelets\"", + "priority": "MEDIUM", + "required": "false" + }, "camel.component.kamelet.routeProperties": { "name": "camel.component.kamelet.routeProperties", "description": "Set route local parameters.", diff --git a/connectors/camel-kamelet-kafka-connector/src/generated/resources/camel-kamelet-source.json b/connectors/camel-kamelet-kafka-connector/src/generated/resources/camel-kamelet-source.json index 4322644..efc4e01 100644 --- a/connectors/camel-kamelet-kafka-connector/src/generated/resources/camel-kamelet-source.json +++ b/connectors/camel-kamelet-kafka-connector/src/generated/resources/camel-kamelet-source.json @@ -45,6 +45,13 @@ "InOptionalOut" ] }, + "camel.component.kamelet.location": { + "name": "camel.component.kamelet.location", + "description": "The location of the Kamelets on the file system.", + "defaultValue": "\"classpath:\/kamelets\"", + "priority": "MEDIUM", + "required": "false" + }, "camel.component.kamelet.routeProperties": { "name": "camel.component.kamelet.routeProperties", "description": "Set route local parameters.", diff --git a/connectors/camel-kamelet-kafka-connector/src/main/docs/camel-kamelet-kafka-sink-connector.adoc b/connectors/camel-kamelet-kafka-connector/src/main/docs/camel-kamelet-kafka-sink-connector.adoc index 3e8a764..579577d 100644 --- a/connectors/camel-kamelet-kafka-connector/src/main/docs/camel-kamelet-kafka-sink-connector.adoc +++ b/connectors/camel-kamelet-kafka-connector/src/main/docs/camel-kamelet-kafka-sink-connector.adoc @@ -24,7 +24,7 @@ connector.class=org.apache.camel.kafkaconnector.kamelet.CamelKameletSinkConnecto ---- -The camel-kamelet sink connector supports 12 options, which are listed below. +The camel-kamelet sink connector supports 13 options, which are listed below. @@ -37,6 +37,7 @@ The camel-kamelet sink connector supports 12 options, which are listed below. | *camel.sink.endpoint.failIfNoConsumers* | Whether the producer should fail by throwing an exception, when sending to a kamelet endpoint with no active consumers. | true | false | MEDIUM | *camel.sink.endpoint.lazyStartProducer* | 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 cre [...] | *camel.sink.endpoint.timeout* | The timeout value to use if block is enabled. | 30000L | false | MEDIUM +| *camel.component.kamelet.location* | The location of the Kamelets on the file system. | "classpath:/kamelets" | false | MEDIUM | *camel.component.kamelet.routeProperties* | Set route local parameters. | null | false | MEDIUM | *camel.component.kamelet.templateProperties* | Set template local parameters. | null | false | MEDIUM | *camel.component.kamelet.block* | If sending a message to a kamelet endpoint which has no active consumer, then we can tell the producer to block and wait for the consumer to become active. | true | false | MEDIUM diff --git a/connectors/camel-kamelet-kafka-connector/src/main/docs/camel-kamelet-kafka-source-connector.adoc b/connectors/camel-kamelet-kafka-connector/src/main/docs/camel-kamelet-kafka-source-connector.adoc index 06ea14f..f2ff66c 100644 --- a/connectors/camel-kamelet-kafka-connector/src/main/docs/camel-kamelet-kafka-source-connector.adoc +++ b/connectors/camel-kamelet-kafka-connector/src/main/docs/camel-kamelet-kafka-source-connector.adoc @@ -24,7 +24,7 @@ connector.class=org.apache.camel.kafkaconnector.kamelet.CamelKameletSourceConnec ---- -The camel-kamelet source connector supports 9 options, which are listed below. +The camel-kamelet source connector supports 10 options, which are listed below. @@ -36,6 +36,7 @@ The camel-kamelet source connector supports 9 options, which are listed below. | *camel.source.endpoint.bridgeErrorHandler* | 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 | false | MEDIUM | *camel.source.endpoint.exceptionHandler* | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored. | null | false | MEDIUM | *camel.source.endpoint.exchangePattern* | Sets the exchange pattern when the consumer creates an exchange. One of: [InOnly] [InOut] [InOptionalOut] | null | false | MEDIUM +| *camel.component.kamelet.location* | The location of the Kamelets on the file system. | "classpath:/kamelets" | false | MEDIUM | *camel.component.kamelet.routeProperties* | Set route local parameters. | null | false | MEDIUM | *camel.component.kamelet.templateProperties* | Set template local parameters. | null | false | MEDIUM | *camel.component.kamelet.bridgeErrorHandler* | 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 | false | MEDIUM diff --git a/connectors/camel-kamelet-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kamelet/CamelKameletSinkConnectorConfig.java b/connectors/camel-kamelet-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kamelet/CamelKameletSinkConnectorConfig.java index 09bc60f..8b44b3c 100644 --- a/connectors/camel-kamelet-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kamelet/CamelKameletSinkConnectorConfig.java +++ b/connectors/camel-kamelet-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kamelet/CamelKameletSinkConnectorConfig.java @@ -42,6 +42,9 @@ public class CamelKameletSinkConnectorConfig extends CamelSinkConnectorConfig { public static final String CAMEL_SINK_KAMELET_ENDPOINT_TIMEOUT_CONF = "camel.sink.endpoint.timeout"; public static final String CAMEL_SINK_KAMELET_ENDPOINT_TIMEOUT_DOC = "The timeout value to use if block is enabled."; public static final Long CAMEL_SINK_KAMELET_ENDPOINT_TIMEOUT_DEFAULT = 30000L; + public static final String CAMEL_SINK_KAMELET_COMPONENT_LOCATION_CONF = "camel.component.kamelet.location"; + public static final String CAMEL_SINK_KAMELET_COMPONENT_LOCATION_DOC = "The location of the Kamelets on the file system."; + public static final String CAMEL_SINK_KAMELET_COMPONENT_LOCATION_DEFAULT = "classpath:/kamelets"; public static final String CAMEL_SINK_KAMELET_COMPONENT_ROUTE_PROPERTIES_CONF = "camel.component.kamelet.routeProperties"; public static final String CAMEL_SINK_KAMELET_COMPONENT_ROUTE_PROPERTIES_DOC = "Set route local parameters."; public static final String CAMEL_SINK_KAMELET_COMPONENT_ROUTE_PROPERTIES_DEFAULT = null; @@ -79,6 +82,7 @@ public class CamelKameletSinkConnectorConfig extends CamelSinkConnectorConfig { conf.define(CAMEL_SINK_KAMELET_ENDPOINT_FAIL_IF_NO_CONSUMERS_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SINK_KAMELET_ENDPOINT_FAIL_IF_NO_CONSUMERS_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELET_ENDPOINT_FAIL_IF_NO_CONSUMERS_DOC); conf.define(CAMEL_SINK_KAMELET_ENDPOINT_LAZY_START_PRODUCER_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SINK_KAMELET_ENDPOINT_LAZY_START_PRODUCER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELET_ENDPOINT_LAZY_START_PRODUCER_DOC); conf.define(CAMEL_SINK_KAMELET_ENDPOINT_TIMEOUT_CONF, ConfigDef.Type.LONG, CAMEL_SINK_KAMELET_ENDPOINT_TIMEOUT_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELET_ENDPOINT_TIMEOUT_DOC); + conf.define(CAMEL_SINK_KAMELET_COMPONENT_LOCATION_CONF, ConfigDef.Type.STRING, CAMEL_SINK_KAMELET_COMPONENT_LOCATION_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELET_COMPONENT_LOCATION_DOC); conf.define(CAMEL_SINK_KAMELET_COMPONENT_ROUTE_PROPERTIES_CONF, ConfigDef.Type.STRING, CAMEL_SINK_KAMELET_COMPONENT_ROUTE_PROPERTIES_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELET_COMPONENT_ROUTE_PROPERTIES_DOC); conf.define(CAMEL_SINK_KAMELET_COMPONENT_TEMPLATE_PROPERTIES_CONF, ConfigDef.Type.STRING, CAMEL_SINK_KAMELET_COMPONENT_TEMPLATE_PROPERTIES_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELET_COMPONENT_TEMPLATE_PROPERTIES_DOC); conf.define(CAMEL_SINK_KAMELET_COMPONENT_BLOCK_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SINK_KAMELET_COMPONENT_BLOCK_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELET_COMPONENT_BLOCK_DOC); diff --git a/connectors/camel-kamelet-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kamelet/CamelKameletSourceConnectorConfig.java b/connectors/camel-kamelet-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kamelet/CamelKameletSourceConnectorConfig.java index 1de3b1a..7d94519 100644 --- a/connectors/camel-kamelet-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kamelet/CamelKameletSourceConnectorConfig.java +++ b/connectors/camel-kamelet-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kamelet/CamelKameletSourceConnectorConfig.java @@ -41,6 +41,9 @@ public class CamelKameletSourceConnectorConfig public static final String CAMEL_SOURCE_KAMELET_ENDPOINT_EXCHANGE_PATTERN_CONF = "camel.source.endpoint.exchangePattern"; public static final String CAMEL_SOURCE_KAMELET_ENDPOINT_EXCHANGE_PATTERN_DOC = "Sets the exchange pattern when the consumer creates an exchange. One of: [InOnly] [InOut] [InOptionalOut]"; public static final String CAMEL_SOURCE_KAMELET_ENDPOINT_EXCHANGE_PATTERN_DEFAULT = null; + public static final String CAMEL_SOURCE_KAMELET_COMPONENT_LOCATION_CONF = "camel.component.kamelet.location"; + public static final String CAMEL_SOURCE_KAMELET_COMPONENT_LOCATION_DOC = "The location of the Kamelets on the file system."; + public static final String CAMEL_SOURCE_KAMELET_COMPONENT_LOCATION_DEFAULT = "classpath:/kamelets"; public static final String CAMEL_SOURCE_KAMELET_COMPONENT_ROUTE_PROPERTIES_CONF = "camel.component.kamelet.routeProperties"; public static final String CAMEL_SOURCE_KAMELET_COMPONENT_ROUTE_PROPERTIES_DOC = "Set route local parameters."; public static final String CAMEL_SOURCE_KAMELET_COMPONENT_ROUTE_PROPERTIES_DEFAULT = null; @@ -71,6 +74,7 @@ public class CamelKameletSourceConnectorConfig conf.define(CAMEL_SOURCE_KAMELET_ENDPOINT_BRIDGE_ERROR_HANDLER_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SOURCE_KAMELET_ENDPOINT_BRIDGE_ERROR_HANDLER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELET_ENDPOINT_BRIDGE_ERROR_HANDLER_DOC); conf.define(CAMEL_SOURCE_KAMELET_ENDPOINT_EXCEPTION_HANDLER_CONF, ConfigDef.Type.STRING, CAMEL_SOURCE_KAMELET_ENDPOINT_EXCEPTION_HANDLER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELET_ENDPOINT_EXCEPTION_HANDLER_DOC); conf.define(CAMEL_SOURCE_KAMELET_ENDPOINT_EXCHANGE_PATTERN_CONF, ConfigDef.Type.STRING, CAMEL_SOURCE_KAMELET_ENDPOINT_EXCHANGE_PATTERN_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELET_ENDPOINT_EXCHANGE_PATTERN_DOC); + conf.define(CAMEL_SOURCE_KAMELET_COMPONENT_LOCATION_CONF, ConfigDef.Type.STRING, CAMEL_SOURCE_KAMELET_COMPONENT_LOCATION_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELET_COMPONENT_LOCATION_DOC); conf.define(CAMEL_SOURCE_KAMELET_COMPONENT_ROUTE_PROPERTIES_CONF, ConfigDef.Type.STRING, CAMEL_SOURCE_KAMELET_COMPONENT_ROUTE_PROPERTIES_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELET_COMPONENT_ROUTE_PROPERTIES_DOC); conf.define(CAMEL_SOURCE_KAMELET_COMPONENT_TEMPLATE_PROPERTIES_CONF, ConfigDef.Type.STRING, CAMEL_SOURCE_KAMELET_COMPONENT_TEMPLATE_PROPERTIES_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELET_COMPONENT_TEMPLATE_PROPERTIES_DOC); conf.define(CAMEL_SOURCE_KAMELET_COMPONENT_BRIDGE_ERROR_HANDLER_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SOURCE_KAMELET_COMPONENT_BRIDGE_ERROR_HANDLER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELET_COMPONENT_BRIDGE_ERROR_HANDLER_DOC); diff --git a/connectors/camel-kamelet-reify-kafka-connector/pom.xml b/connectors/camel-kamelet-reify-kafka-connector/pom.xml new file mode 100644 index 0000000..d17cc08 --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/pom.xml @@ -0,0 +1,139 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + <modelVersion>4.0.0</modelVersion> + <parent> + <groupId>org.apache.camel.kafkaconnector</groupId> + <artifactId>connectors</artifactId> + <version>0.10.0-SNAPSHOT</version> + </parent> + <artifactId>camel-kamelet-reify-kafka-connector</artifactId> + <name>Camel-Kafka-Connector :: kamelet-reify</name> + <description>Camel Kafka Connector for kamelet-reify</description> + <dependencies> + <!-- Kafka --> + <dependency> + <groupId>org.apache.kafka</groupId> + <artifactId>connect-api</artifactId> + <scope>provided</scope> + </dependency> + <dependency> + <groupId>org.apache.kafka</groupId> + <artifactId>connect-transforms</artifactId> + <scope>provided</scope> + </dependency> + <!-- Camel --> + <dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-kamelet-reify</artifactId> + </dependency> + <!--START OF GENERATED CODE--> + <dependency> + <groupId>org.apache.camel.kafkaconnector</groupId> + <artifactId>camel-kafka-connector</artifactId> + </dependency> + <dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-jackson</artifactId> + </dependency> + <!--END OF GENERATED CODE--> + </dependencies> + <build> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-surefire-plugin</artifactId> + <version>${version.maven.surefire.plugin}</version> + <configuration> + <failIfNoTests>false</failIfNoTests> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-jar-plugin</artifactId> + <version>${version.maven.jar}</version> + <configuration> + <archive> + <manifest> + <addDefaultImplementationEntries>true</addDefaultImplementationEntries> + <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries> + </manifest> + </archive> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-compiler-plugin</artifactId> + <version>2.5.1</version> + <inherited>true</inherited> + <configuration> + <source>1.8</source> + <target>1.8</target> + </configuration> + </plugin> + <plugin> + <artifactId>maven-assembly-plugin</artifactId> + <version>2.5.3</version> + <configuration> + <descriptors> + <descriptor>src/main/assembly/package.xml</descriptor> + </descriptors> + </configuration> + <executions> + <execution> + <id>make-assembly</id> + <phase>package</phase> + <goals> + <goal>single</goal> + </goals> + </execution> + </executions> + </plugin> + </plugins> + </build> + <!--START OF GENERATED CODE--> + <repositories> + <!-- camel-jira --> + <repository> + <id>atlassian-public</id> + <url>https://packages.atlassian.com/maven-external</url> + <name>Atlassian Public Repo</name> + <snapshots> + <enabled>false</enabled> + </snapshots> + <releases> + <enabled>true</enabled> + </releases> + </repository> + <!-- camel-ipfs and camel-weka --> + <repository> + <id>jboss.thirdparty</id> + <name>JBoss Thirdparty Repository</name> + <url>https://repository.jboss.org/nexus/service/local/repositories/thirdparty-releases/content/</url> + <snapshots> + <enabled>false</enabled> + </snapshots> + <releases> + <enabled>true</enabled> + </releases> + </repository> + </repositories> + <!--END OF GENERATED CODE--> +</project> diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/generated/descriptors/connector-sink.properties b/connectors/camel-kamelet-reify-kafka-connector/src/generated/descriptors/connector-sink.properties new file mode 100644 index 0000000..ccbdd8a --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/generated/descriptors/connector-sink.properties @@ -0,0 +1 @@ +camel-kamelet-reify-sink \ No newline at end of file diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/generated/descriptors/connector-source.properties b/connectors/camel-kamelet-reify-kafka-connector/src/generated/descriptors/connector-source.properties new file mode 100644 index 0000000..432ba99 --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/generated/descriptors/connector-source.properties @@ -0,0 +1 @@ +camel-kamelet-reify-source \ No newline at end of file diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/generated/resources/camel-kamelet-reify-sink.json b/connectors/camel-kamelet-reify-kafka-connector/src/generated/resources/camel-kamelet-reify-sink.json new file mode 100644 index 0000000..68dd902 --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/generated/resources/camel-kamelet-reify-sink.json @@ -0,0 +1,40 @@ +{ + "connector": { + "class": "org.apache.camel.kafkaconnector.kameletreify.CamelKameletreifySinkConnector", + "artifactId": "camel-kamelet-reify-kafka-connector", + "groupId": "org.apache.camel.kafkaconnector", + "id": "camel-kamelet-reify-sink", + "type": "sink", + "version": "0.10.0-SNAPSHOT", + "description": "To call Kamelets (indirectly)" + }, + "properties": { + "camel.sink.path.delegateUri": { + "name": "camel.sink.path.delegateUri", + "description": "The delegated uri", + "priority": "HIGH", + "required": "true" + }, + "camel.sink.endpoint.lazyStartProducer": { + "name": "camel.sink.endpoint.lazyStartProducer", + "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 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 starting the pr [...] + "defaultValue": "false", + "priority": "MEDIUM", + "required": "false" + }, + "camel.component.kamelet-reify.lazyStartProducer": { + "name": "camel.component.kamelet-reify.lazyStartProducer", + "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 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 starting the pr [...] + "defaultValue": "false", + "priority": "MEDIUM", + "required": "false" + }, + "camel.component.kamelet-reify.autowiredEnabled": { + "name": "camel.component.kamelet-reify.autowiredEnabled", + "description": "Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc.", + "defaultValue": "true", + "priority": "MEDIUM", + "required": "false" + } + } +} diff --git a/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-source.json b/connectors/camel-kamelet-reify-kafka-connector/src/generated/resources/camel-kamelet-reify-source.json similarity index 68% copy from camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-source.json copy to connectors/camel-kamelet-reify-kafka-connector/src/generated/resources/camel-kamelet-reify-source.json index 4322644..d85a100 100644 --- a/camel-kafka-connector-catalog/src/generated/resources/connectors/camel-kamelet-source.json +++ b/connectors/camel-kamelet-reify-kafka-connector/src/generated/resources/camel-kamelet-reify-source.json @@ -1,26 +1,20 @@ { "connector": { - "class": "org.apache.camel.kafkaconnector.kamelet.CamelKameletSourceConnector", - "artifactId": "camel-kamelet-kafka-connector", + "class": "org.apache.camel.kafkaconnector.kameletreify.CamelKameletreifySourceConnector", + "artifactId": "camel-kamelet-reify-kafka-connector", "groupId": "org.apache.camel.kafkaconnector", - "id": "camel-kamelet-source", + "id": "camel-kamelet-reify-source", "type": "source", "version": "0.10.0-SNAPSHOT", - "description": "To call Kamelets" + "description": "To call Kamelets (indirectly)" }, "properties": { - "camel.source.path.templateId": { - "name": "camel.source.path.templateId", - "description": "The Route Template ID", + "camel.source.path.delegateUri": { + "name": "camel.source.path.delegateUri", + "description": "The delegated uri", "priority": "HIGH", "required": "true" }, - "camel.source.path.routeId": { - "name": "camel.source.path.routeId", - "description": "The Route ID. Default value notice: The ID will be auto-generated if not provided", - "priority": "MEDIUM", - "required": "false" - }, "camel.source.endpoint.bridgeErrorHandler": { "name": "camel.source.endpoint.bridgeErrorHandler", "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 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.", @@ -45,31 +39,19 @@ "InOptionalOut" ] }, - "camel.component.kamelet.routeProperties": { - "name": "camel.component.kamelet.routeProperties", - "description": "Set route local parameters.", - "priority": "MEDIUM", - "required": "false" - }, - "camel.component.kamelet.templateProperties": { - "name": "camel.component.kamelet.templateProperties", - "description": "Set template local parameters.", - "priority": "MEDIUM", - "required": "false" - }, - "camel.component.kamelet.bridgeErrorHandler": { - "name": "camel.component.kamelet.bridgeErrorHandler", + "camel.component.kamelet-reify.bridgeErrorHandler": { + "name": "camel.component.kamelet-reify.bridgeErrorHandler", "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 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.", "defaultValue": "false", "priority": "MEDIUM", "required": "false" }, - "camel.component.kamelet.autowiredEnabled": { - "name": "camel.component.kamelet.autowiredEnabled", + "camel.component.kamelet-reify.autowiredEnabled": { + "name": "camel.component.kamelet-reify.autowiredEnabled", "description": "Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc.", "defaultValue": "true", "priority": "MEDIUM", "required": "false" } } -} \ No newline at end of file +} diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/assembly/package.xml b/connectors/camel-kamelet-reify-kafka-connector/src/main/assembly/package.xml new file mode 100644 index 0000000..05f0b1a --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/assembly/package.xml @@ -0,0 +1,56 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--> +<assembly> + <!-- Assembles a packaged version targeting OS installation. --> + <id>package</id> + <formats> + <format>tar.gz</format> + </formats> + <includeBaseDirectory>false</includeBaseDirectory> + <fileSets> + <fileSet> + <directory>${project.basedir}/../..</directory> + <outputDirectory>${project.artifactId}/</outputDirectory> + <includes> + <include>README*</include> + <include>LICENSE*</include> + <include>NOTICE*</include> + <include>licenses/</include> + </includes> + </fileSet> + <fileSet> + <directory>${project.basedir}/src/main/docs</directory> + <outputDirectory>docs/</outputDirectory> + <includes> + <include>**/*</include> + </includes> + </fileSet> + </fileSets> + <dependencySets> + <dependencySet> + <outputDirectory>${project.artifactId}/</outputDirectory> + <useProjectArtifact>true</useProjectArtifact> + <useTransitiveFiltering>true</useTransitiveFiltering> + <excludes> + <exclude>org.apache.kafka:connect-api</exclude> + </excludes> + </dependencySet> + </dependencySets> +</assembly> diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/camel-kamelet-reify-kafka-sink-connector.adoc b/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/camel-kamelet-reify-kafka-sink-connector.adoc new file mode 100644 index 0000000..053c2c1 --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/camel-kamelet-reify-kafka-sink-connector.adoc @@ -0,0 +1,59 @@ +// kafka-connector options: START +[[camel-kamelet-reify-kafka-connector-sink]] += camel-kamelet-reify-kafka-connector sink configuration + +Connector Description: To call Kamelets (indirectly) + +When using camel-kamelet-reify-kafka-connector as sink make sure to use the following Maven dependency to have support for the connector: + +[source,xml] +---- +<dependency> + <groupId>org.apache.camel.kafkaconnector</groupId> + <artifactId>camel-kamelet-reify-kafka-connector</artifactId> + <version>x.x.x</version> + <!-- use the same version as your Camel Kafka connector version --> +</dependency> +---- + +To use this Sink connector in Kafka connect you'll need to set the following connector.class + +[source,java] +---- +connector.class=org.apache.camel.kafkaconnector.kameletreify.CamelKameletreifySinkConnector +---- + + +The camel-kamelet-reify sink connector supports 4 options, which are listed below. + + + +[width="100%",cols="2,5,^1,1,1",options="header"] +|=== +| Name | Description | Default | Required | Priority +| *camel.sink.path.delegateUri* | The delegated uri | null | true | HIGH +| *camel.sink.endpoint.lazyStartProducer* | 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 cre [...] +| *camel.component.kamelet-reify.lazyStartProducer* | 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 processe [...] +| *camel.component.kamelet-reify.autowiredEnabled* | Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc. | true | false | MEDIUM +|=== + + + +The camel-kamelet-reify sink connector has no converters out of the box. + + + + + +The camel-kamelet-reify sink connector has no transforms out of the box. + + + + + +The camel-kamelet-reify sink connector has no aggregation strategies out of the box. + + + + +// kafka-connector options: END diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/camel-kamelet-reify-kafka-source-connector.adoc b/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/camel-kamelet-reify-kafka-source-connector.adoc new file mode 100644 index 0000000..ec0d04d --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/camel-kamelet-reify-kafka-source-connector.adoc @@ -0,0 +1,61 @@ +// kafka-connector options: START +[[camel-kamelet-reify-kafka-connector-source]] += camel-kamelet-reify-kafka-connector source configuration + +Connector description: To call Kamelets (indirectly) + +When using camel-kamelet-reify-kafka-connector as source make sure to use the following Maven dependency to have support for the connector: + +[source,xml] +---- +<dependency> + <groupId>org.apache.camel.kafkaconnector</groupId> + <artifactId>camel-kamelet-reify-kafka-connector</artifactId> + <version>x.x.x</version> + <!-- use the same version as your Camel Kafka connector version --> +</dependency> +---- + +To use this Source connector in Kafka connect you'll need to set the following connector.class + +[source,java] +---- +connector.class=org.apache.camel.kafkaconnector.kameletreify.CamelKameletreifySourceConnector +---- + + +The camel-kamelet-reify source connector supports 6 options, which are listed below. + + + +[width="100%",cols="2,5,^1,1,1",options="header"] +|=== +| Name | Description | Default | Required | Priority +| *camel.source.path.delegateUri* | The delegated uri | null | true | HIGH +| *camel.source.endpoint.bridgeErrorHandler* | 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 | false | MEDIUM +| *camel.source.endpoint.exceptionHandler* | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored. | null | false | MEDIUM +| *camel.source.endpoint.exchangePattern* | Sets the exchange pattern when the consumer creates an exchange. One of: [InOnly] [InOut] [InOptionalOut] | null | false | MEDIUM +| *camel.component.kamelet-reify.bridgeErrorHandler* | 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 | false | MEDIUM +| *camel.component.kamelet-reify.autowiredEnabled* | Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc. | true | false | MEDIUM +|=== + + + +The camel-kamelet-reify source connector has no converters out of the box. + + + + + +The camel-kamelet-reify source connector has no transforms out of the box. + + + + + +The camel-kamelet-reify source connector has no aggregation strategies out of the box. + + + + +// kafka-connector options: END diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/examples/CamelKameletreifySinkConnector.properties b/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/examples/CamelKameletreifySinkConnector.properties new file mode 100644 index 0000000..b92a18d --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/examples/CamelKameletreifySinkConnector.properties @@ -0,0 +1,33 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- + +name=CamelKamelet-reifySinkConnector +connector.class=org.apache.camel.kafkaconnector.kameletreify.CamelKameletreifySinkConnector +tasks.max=1 + +# use the kafka converters that better suit your needs, these are just defaults: +key.converter=org.apache.kafka.connect.storage.StringConverter +value.converter=org.apache.kafka.connect.storage.StringConverter + +# comma separated topics to get messages from +topics= + +# mandatory properties (for a complete properties list see the connector documentation): + +# The delegated uri +camel.sink.path.delegateUri= + diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/examples/CamelKameletreifySourceConnector.properties b/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/examples/CamelKameletreifySourceConnector.properties new file mode 100644 index 0000000..df58c3b --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/docs/examples/CamelKameletreifySourceConnector.properties @@ -0,0 +1,33 @@ +## --------------------------------------------------------------------------- +## Licensed to the Apache Software Foundation (ASF) under one or more +## contributor license agreements. See the NOTICE file distributed with +## this work for additional information regarding copyright ownership. +## The ASF licenses this file to You under the Apache License, Version 2.0 +## (the "License"); you may not use this file except in compliance with +## the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## --------------------------------------------------------------------------- + +name=CamelKamelet-reifySourceConnector +connector.class=org.apache.camel.kafkaconnector.kameletreify.CamelKameletreifySourceConnector +tasks.max=1 + +# use the kafka converters that better suit your needs, these are just defaults: +key.converter=org.apache.kafka.connect.storage.StringConverter +value.converter=org.apache.kafka.connect.storage.StringConverter + +# comma separated topics to send messages into +topics= + +# mandatory properties (for a complete properties list see the connector documentation): + +# The delegated uri +camel.source.path.delegateUri= + diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkConnector.java b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkConnector.java new file mode 100644 index 0000000..d93a1bf --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkConnector.java @@ -0,0 +1,35 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.kafkaconnector.kameletreify; + +import javax.annotation.Generated; +import org.apache.camel.kafkaconnector.CamelSinkConnector; +import org.apache.kafka.common.config.ConfigDef; +import org.apache.kafka.connect.connector.Task; + +@Generated("This class has been generated by camel-kafka-connector-generator-maven-plugin, remove this annotation to prevent it from being generated.") +public class CamelKameletreifySinkConnector extends CamelSinkConnector { + + @Override + public ConfigDef config() { + return CamelKameletreifySinkConnectorConfig.conf(); + } + @Override + public Class<? extends Task> taskClass() { + return CamelKameletreifySinkTask.class; + } +} \ No newline at end of file diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkConnectorConfig.java b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkConnectorConfig.java new file mode 100644 index 0000000..affbfc3 --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkConnectorConfig.java @@ -0,0 +1,60 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.kafkaconnector.kameletreify; + +import java.util.Map; +import javax.annotation.Generated; +import org.apache.camel.kafkaconnector.CamelSinkConnectorConfig; +import org.apache.kafka.common.config.ConfigDef; + +@Generated("This class has been generated by camel-kafka-connector-generator-maven-plugin, remove this annotation to prevent it from being generated.") +public class CamelKameletreifySinkConnectorConfig + extends + CamelSinkConnectorConfig { + + public static final String CAMEL_SINK_KAMELETREIFY_PATH_DELEGATE_URI_CONF = "camel.sink.path.delegateUri"; + public static final String CAMEL_SINK_KAMELETREIFY_PATH_DELEGATE_URI_DOC = "The delegated uri"; + public static final String CAMEL_SINK_KAMELETREIFY_PATH_DELEGATE_URI_DEFAULT = null; + public static final String CAMEL_SINK_KAMELETREIFY_ENDPOINT_LAZY_START_PRODUCER_CONF = "camel.sink.endpoint.lazyStartProducer"; + public static final String CAMEL_SINK_KAMELETREIFY_ENDPOINT_LAZY_START_PRODUCER_DOC = "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 th [...] + public static final Boolean CAMEL_SINK_KAMELETREIFY_ENDPOINT_LAZY_START_PRODUCER_DEFAULT = false; + public static final String CAMEL_SINK_KAMELETREIFY_COMPONENT_LAZY_START_PRODUCER_CONF = "camel.component.kamelet-reify.lazyStartProducer"; + public static final String CAMEL_SINK_KAMELETREIFY_COMPONENT_LAZY_START_PRODUCER_DOC = "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 t [...] + public static final Boolean CAMEL_SINK_KAMELETREIFY_COMPONENT_LAZY_START_PRODUCER_DEFAULT = false; + public static final String CAMEL_SINK_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_CONF = "camel.component.kamelet-reify.autowiredEnabled"; + public static final String CAMEL_SINK_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_DOC = "Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc."; + public static final Boolean CAMEL_SINK_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_DEFAULT = true; + + public CamelKameletreifySinkConnectorConfig( + ConfigDef config, + Map<String, String> parsedConfig) { + super(config, parsedConfig); + } + + public CamelKameletreifySinkConnectorConfig(Map<String, String> parsedConfig) { + this(conf(), parsedConfig); + } + + public static ConfigDef conf() { + ConfigDef conf = new ConfigDef(CamelSinkConnectorConfig.conf()); + conf.define(CAMEL_SINK_KAMELETREIFY_PATH_DELEGATE_URI_CONF, ConfigDef.Type.STRING, CAMEL_SINK_KAMELETREIFY_PATH_DELEGATE_URI_DEFAULT, ConfigDef.Importance.HIGH, CAMEL_SINK_KAMELETREIFY_PATH_DELEGATE_URI_DOC); + conf.define(CAMEL_SINK_KAMELETREIFY_ENDPOINT_LAZY_START_PRODUCER_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SINK_KAMELETREIFY_ENDPOINT_LAZY_START_PRODUCER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELETREIFY_ENDPOINT_LAZY_START_PRODUCER_DOC); + conf.define(CAMEL_SINK_KAMELETREIFY_COMPONENT_LAZY_START_PRODUCER_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SINK_KAMELETREIFY_COMPONENT_LAZY_START_PRODUCER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELETREIFY_COMPONENT_LAZY_START_PRODUCER_DOC); + conf.define(CAMEL_SINK_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SINK_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SINK_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_DOC); + return conf; + } +} \ No newline at end of file diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkTask.java b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkTask.java new file mode 100644 index 0000000..206a823 --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySinkTask.java @@ -0,0 +1,39 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.kafkaconnector.kameletreify; + +import java.util.HashMap; +import java.util.Map; +import javax.annotation.Generated; +import org.apache.camel.kafkaconnector.CamelSinkConnectorConfig; +import org.apache.camel.kafkaconnector.CamelSinkTask; + +@Generated("This class has been generated by camel-kafka-connector-generator-maven-plugin, remove this annotation to prevent it from being generated.") +public class CamelKameletreifySinkTask extends CamelSinkTask { + + @Override + protected CamelSinkConnectorConfig getCamelSinkConnectorConfig( + Map<String, String> props) { + return new CamelKameletreifySinkConnectorConfig(props); + } + @Override + protected Map<String, String> getDefaultConfig() { + return new HashMap<String, String>() {{ + put(CamelSinkConnectorConfig.CAMEL_SINK_COMPONENT_CONF, "kamelet-reify"); + }}; + } +} \ No newline at end of file diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceConnector.java b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceConnector.java new file mode 100644 index 0000000..bf60b7b --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceConnector.java @@ -0,0 +1,35 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.kafkaconnector.kameletreify; + +import javax.annotation.Generated; +import org.apache.camel.kafkaconnector.CamelSourceConnector; +import org.apache.kafka.common.config.ConfigDef; +import org.apache.kafka.connect.connector.Task; + +@Generated("This class has been generated by camel-kafka-connector-generator-maven-plugin, remove this annotation to prevent it from being generated.") +public class CamelKameletreifySourceConnector extends CamelSourceConnector { + + @Override + public ConfigDef config() { + return CamelKameletreifySourceConnectorConfig.conf(); + } + @Override + public Class<? extends Task> taskClass() { + return CamelKameletreifySourceTask.class; + } +} \ No newline at end of file diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceConnectorConfig.java b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceConnectorConfig.java new file mode 100644 index 0000000..334421f --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceConnectorConfig.java @@ -0,0 +1,69 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.kafkaconnector.kameletreify; + +import java.util.Map; +import javax.annotation.Generated; +import org.apache.camel.kafkaconnector.CamelSourceConnectorConfig; +import org.apache.kafka.common.config.ConfigDef; + +@Generated("This class has been generated by camel-kafka-connector-generator-maven-plugin, remove this annotation to prevent it from being generated.") +public class CamelKameletreifySourceConnectorConfig + extends + CamelSourceConnectorConfig { + + public static final String CAMEL_SOURCE_KAMELETREIFY_PATH_DELEGATE_URI_CONF = "camel.source.path.delegateUri"; + public static final String CAMEL_SOURCE_KAMELETREIFY_PATH_DELEGATE_URI_DOC = "The delegated uri"; + public static final String CAMEL_SOURCE_KAMELETREIFY_PATH_DELEGATE_URI_DEFAULT = null; + public static final String CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_BRIDGE_ERROR_HANDLER_CONF = "camel.source.endpoint.bridgeErrorHandler"; + public static final String CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_BRIDGE_ERROR_HANDLER_DOC = "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 an [...] + public static final Boolean CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_BRIDGE_ERROR_HANDLER_DEFAULT = false; + public static final String CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCEPTION_HANDLER_CONF = "camel.source.endpoint.exceptionHandler"; + public static final String CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCEPTION_HANDLER_DOC = "To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored."; + public static final String CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCEPTION_HANDLER_DEFAULT = null; + public static final String CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCHANGE_PATTERN_CONF = "camel.source.endpoint.exchangePattern"; + public static final String CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCHANGE_PATTERN_DOC = "Sets the exchange pattern when the consumer creates an exchange. One of: [InOnly] [InOut] [InOptionalOut]"; + public static final String CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCHANGE_PATTERN_DEFAULT = null; + public static final String CAMEL_SOURCE_KAMELETREIFY_COMPONENT_BRIDGE_ERROR_HANDLER_CONF = "camel.component.kamelet-reify.bridgeErrorHandler"; + public static final String CAMEL_SOURCE_KAMELETREIFY_COMPONENT_BRIDGE_ERROR_HANDLER_DOC = "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 a [...] + public static final Boolean CAMEL_SOURCE_KAMELETREIFY_COMPONENT_BRIDGE_ERROR_HANDLER_DEFAULT = false; + public static final String CAMEL_SOURCE_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_CONF = "camel.component.kamelet-reify.autowiredEnabled"; + public static final String CAMEL_SOURCE_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_DOC = "Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc."; + public static final Boolean CAMEL_SOURCE_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_DEFAULT = true; + + public CamelKameletreifySourceConnectorConfig( + ConfigDef config, + Map<String, String> parsedConfig) { + super(config, parsedConfig); + } + + public CamelKameletreifySourceConnectorConfig( + Map<String, String> parsedConfig) { + this(conf(), parsedConfig); + } + + public static ConfigDef conf() { + ConfigDef conf = new ConfigDef(CamelSourceConnectorConfig.conf()); + conf.define(CAMEL_SOURCE_KAMELETREIFY_PATH_DELEGATE_URI_CONF, ConfigDef.Type.STRING, CAMEL_SOURCE_KAMELETREIFY_PATH_DELEGATE_URI_DEFAULT, ConfigDef.Importance.HIGH, CAMEL_SOURCE_KAMELETREIFY_PATH_DELEGATE_URI_DOC); + conf.define(CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_BRIDGE_ERROR_HANDLER_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_BRIDGE_ERROR_HANDLER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_BRIDGE_ERROR_HANDLER_DOC); + conf.define(CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCEPTION_HANDLER_CONF, ConfigDef.Type.STRING, CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCEPTION_HANDLER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCEPTION_HANDLER_DOC); + conf.define(CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCHANGE_PATTERN_CONF, ConfigDef.Type.STRING, CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCHANGE_PATTERN_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELETREIFY_ENDPOINT_EXCHANGE_PATTERN_DOC); + conf.define(CAMEL_SOURCE_KAMELETREIFY_COMPONENT_BRIDGE_ERROR_HANDLER_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SOURCE_KAMELETREIFY_COMPONENT_BRIDGE_ERROR_HANDLER_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELETREIFY_COMPONENT_BRIDGE_ERROR_HANDLER_DOC); + conf.define(CAMEL_SOURCE_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_CONF, ConfigDef.Type.BOOLEAN, CAMEL_SOURCE_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_DEFAULT, ConfigDef.Importance.MEDIUM, CAMEL_SOURCE_KAMELETREIFY_COMPONENT_AUTOWIRED_ENABLED_DOC); + return conf; + } +} \ No newline at end of file diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceTask.java b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceTask.java new file mode 100644 index 0000000..b400e1c --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/java/org/apache/camel/kafkaconnector/kameletreify/CamelKameletreifySourceTask.java @@ -0,0 +1,39 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.kafkaconnector.kameletreify; + +import java.util.HashMap; +import java.util.Map; +import javax.annotation.Generated; +import org.apache.camel.kafkaconnector.CamelSourceConnectorConfig; +import org.apache.camel.kafkaconnector.CamelSourceTask; + +@Generated("This class has been generated by camel-kafka-connector-generator-maven-plugin, remove this annotation to prevent it from being generated.") +public class CamelKameletreifySourceTask extends CamelSourceTask { + + @Override + protected CamelSourceConnectorConfig getCamelSourceConnectorConfig( + Map<String, String> props) { + return new CamelKameletreifySourceConnectorConfig(props); + } + @Override + protected Map<String, String> getDefaultConfig() { + return new HashMap<String, String>() {{ + put(CamelSourceConnectorConfig.CAMEL_SOURCE_COMPONENT_CONF, "kamelet-reify"); + }}; + } +} \ No newline at end of file diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/resources/META-INF/LICENSE.txt b/connectors/camel-kamelet-reify-kafka-connector/src/main/resources/META-INF/LICENSE.txt new file mode 100644 index 0000000..6b0b127 --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/resources/META-INF/LICENSE.txt @@ -0,0 +1,203 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + diff --git a/connectors/camel-kamelet-reify-kafka-connector/src/main/resources/META-INF/NOTICE.txt b/connectors/camel-kamelet-reify-kafka-connector/src/main/resources/META-INF/NOTICE.txt new file mode 100644 index 0000000..2e215bf --- /dev/null +++ b/connectors/camel-kamelet-reify-kafka-connector/src/main/resources/META-INF/NOTICE.txt @@ -0,0 +1,11 @@ + ========================================================================= + == NOTICE file corresponding to the section 4 d of == + == the Apache License, Version 2.0, == + == in this case for the Apache Camel distribution. == + ========================================================================= + + This product includes software developed by + The Apache Software Foundation (http://www.apache.org/). + + Please read the different LICENSE files present in the licenses directory of + this distribution. diff --git a/connectors/pom.xml b/connectors/pom.xml index 9cb2ca1..9435100 100644 --- a/connectors/pom.xml +++ b/connectors/pom.xml @@ -371,6 +371,7 @@ <module>camel-jt400-kafka-connector</module> <module>camel-kafka-kafka-connector</module> <module>camel-kamelet-kafka-connector</module> + <module>camel-kamelet-reify-kafka-connector</module> <module>camel-kubernetes-config-maps-kafka-connector</module> <module>camel-kubernetes-custom-resources-kafka-connector</module> <module>camel-kubernetes-deployments-kafka-connector</module> diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc index 428a58d..757b195 100644 --- a/docs/modules/ROOT/nav.adoc +++ b/docs/modules/ROOT/nav.adoc @@ -471,6 +471,9 @@ ** camel-kamelet-kafka-connector *** xref:connectors/camel-kamelet-kafka-source-connector.adoc[Source Docs] *** xref:connectors/camel-kamelet-kafka-sink-connector.adoc[Sink Docs] +** camel-kamelet-reify-kafka-connector +*** xref:connectors/camel-kamelet-reify-kafka-source-connector.adoc[Source Docs] +*** xref:connectors/camel-kamelet-reify-kafka-sink-connector.adoc[Sink Docs] ** camel-kubernetes-config-maps-kafka-connector *** xref:connectors/camel-kubernetes-config-maps-kafka-sink-connector.adoc[Sink Docs] ** camel-kubernetes-custom-resources-kafka-connector diff --git a/docs/modules/ROOT/pages/connectors.adoc b/docs/modules/ROOT/pages/connectors.adoc index 144d4a4..2f7344b 100644 --- a/docs/modules/ROOT/pages/connectors.adoc +++ b/docs/modules/ROOT/pages/connectors.adoc @@ -2,7 +2,7 @@ = Supported connectors and documentation // kafka-connectors list: START -Number of Camel Kafka connectors: 338 +Number of Camel Kafka connectors: 339 [width="100%",cols="4,1,1,1,1,1",options="header"] |=== @@ -185,6 +185,7 @@ Number of Camel Kafka connectors: 338 | *camel-jt400-kafka-connector* | true | true | xref:connectors/camel-jt400-kafka-sink-connector.adoc[Sink Docs] | xref:connectors/camel-jt400-kafka-source-connector.adoc[Source Docs] | https://repo.maven.apache.org/maven2/org/apache/camel/kafkaconnector/camel-jt400-kafka-connector/0.9.0/camel-jt400-kafka-connector-0.9.0-package.tar.gz[Download] | *camel-kafka-kafka-connector* | true | true | xref:connectors/camel-kafka-kafka-sink-connector.adoc[Sink Docs] | xref:connectors/camel-kafka-kafka-source-connector.adoc[Source Docs] | https://repo.maven.apache.org/maven2/org/apache/camel/kafkaconnector/camel-kafka-kafka-connector/0.9.0/camel-kafka-kafka-connector-0.9.0-package.tar.gz[Download] | *camel-kamelet-kafka-connector* | true | true | xref:connectors/camel-kamelet-kafka-sink-connector.adoc[Sink Docs] | xref:connectors/camel-kamelet-kafka-source-connector.adoc[Source Docs] | https://repo.maven.apache.org/maven2/org/apache/camel/kafkaconnector/camel-kamelet-kafka-connector/0.9.0/camel-kamelet-kafka-connector-0.9.0-package.tar.gz[Download] +| *camel-kamelet-reify-kafka-connector* | true | true | xref:connectors/camel-kamelet-reify-kafka-sink-connector.adoc[Sink Docs] | xref:connectors/camel-kamelet-reify-kafka-source-connector.adoc[Source Docs] | https://repo.maven.apache.org/maven2/org/apache/camel/kafkaconnector/camel-kamelet-reify-kafka-connector/0.9.0/camel-kamelet-reify-kafka-connector-0.9.0-package.tar.gz[Download] | *camel-kubernetes-config-maps-kafka-connector* | true | false | xref:connectors/camel-kubernetes-config-maps-kafka-sink-connector.adoc[Sink Docs] | | https://repo.maven.apache.org/maven2/org/apache/camel/kafkaconnector/camel-kubernetes-config-maps-kafka-connector/0.9.0/camel-kubernetes-config-maps-kafka-connector-0.9.0-package.tar.gz[Download] | *camel-kubernetes-custom-resources-kafka-connector* | true | true | xref:connectors/camel-kubernetes-custom-resources-kafka-sink-connector.adoc[Sink Docs] | xref:connectors/camel-kubernetes-custom-resources-kafka-source-connector.adoc[Source Docs] | https://repo.maven.apache.org/maven2/org/apache/camel/kafkaconnector/camel-kubernetes-custom-resources-kafka-connector/0.9.0/camel-kubernetes-custom-resources-kafka-connector-0.9.0-package.tar.gz[Download] | *camel-kubernetes-deployments-kafka-connector* | true | true | xref:connectors/camel-kubernetes-deployments-kafka-sink-connector.adoc[Sink Docs] | xref:connectors/camel-kubernetes-deployments-kafka-source-connector.adoc[Source Docs] | https://repo.maven.apache.org/maven2/org/apache/camel/kafkaconnector/camel-kubernetes-deployments-kafka-connector/0.9.0/camel-kubernetes-deployments-kafka-connector-0.9.0-package.tar.gz[Download] diff --git a/docs/modules/ROOT/pages/connectors/camel-kamelet-kafka-sink-connector.adoc b/docs/modules/ROOT/pages/connectors/camel-kamelet-kafka-sink-connector.adoc index 3e8a764..579577d 100644 --- a/docs/modules/ROOT/pages/connectors/camel-kamelet-kafka-sink-connector.adoc +++ b/docs/modules/ROOT/pages/connectors/camel-kamelet-kafka-sink-connector.adoc @@ -24,7 +24,7 @@ connector.class=org.apache.camel.kafkaconnector.kamelet.CamelKameletSinkConnecto ---- -The camel-kamelet sink connector supports 12 options, which are listed below. +The camel-kamelet sink connector supports 13 options, which are listed below. @@ -37,6 +37,7 @@ The camel-kamelet sink connector supports 12 options, which are listed below. | *camel.sink.endpoint.failIfNoConsumers* | Whether the producer should fail by throwing an exception, when sending to a kamelet endpoint with no active consumers. | true | false | MEDIUM | *camel.sink.endpoint.lazyStartProducer* | 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 cre [...] | *camel.sink.endpoint.timeout* | The timeout value to use if block is enabled. | 30000L | false | MEDIUM +| *camel.component.kamelet.location* | The location of the Kamelets on the file system. | "classpath:/kamelets" | false | MEDIUM | *camel.component.kamelet.routeProperties* | Set route local parameters. | null | false | MEDIUM | *camel.component.kamelet.templateProperties* | Set template local parameters. | null | false | MEDIUM | *camel.component.kamelet.block* | If sending a message to a kamelet endpoint which has no active consumer, then we can tell the producer to block and wait for the consumer to become active. | true | false | MEDIUM diff --git a/docs/modules/ROOT/pages/connectors/camel-kamelet-kafka-source-connector.adoc b/docs/modules/ROOT/pages/connectors/camel-kamelet-kafka-source-connector.adoc index 06ea14f..f2ff66c 100644 --- a/docs/modules/ROOT/pages/connectors/camel-kamelet-kafka-source-connector.adoc +++ b/docs/modules/ROOT/pages/connectors/camel-kamelet-kafka-source-connector.adoc @@ -24,7 +24,7 @@ connector.class=org.apache.camel.kafkaconnector.kamelet.CamelKameletSourceConnec ---- -The camel-kamelet source connector supports 9 options, which are listed below. +The camel-kamelet source connector supports 10 options, which are listed below. @@ -36,6 +36,7 @@ The camel-kamelet source connector supports 9 options, which are listed below. | *camel.source.endpoint.bridgeErrorHandler* | 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 | false | MEDIUM | *camel.source.endpoint.exceptionHandler* | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored. | null | false | MEDIUM | *camel.source.endpoint.exchangePattern* | Sets the exchange pattern when the consumer creates an exchange. One of: [InOnly] [InOut] [InOptionalOut] | null | false | MEDIUM +| *camel.component.kamelet.location* | The location of the Kamelets on the file system. | "classpath:/kamelets" | false | MEDIUM | *camel.component.kamelet.routeProperties* | Set route local parameters. | null | false | MEDIUM | *camel.component.kamelet.templateProperties* | Set template local parameters. | null | false | MEDIUM | *camel.component.kamelet.bridgeErrorHandler* | 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 | false | MEDIUM diff --git a/docs/modules/ROOT/pages/connectors/camel-kamelet-reify-kafka-sink-connector.adoc b/docs/modules/ROOT/pages/connectors/camel-kamelet-reify-kafka-sink-connector.adoc new file mode 100644 index 0000000..053c2c1 --- /dev/null +++ b/docs/modules/ROOT/pages/connectors/camel-kamelet-reify-kafka-sink-connector.adoc @@ -0,0 +1,59 @@ +// kafka-connector options: START +[[camel-kamelet-reify-kafka-connector-sink]] += camel-kamelet-reify-kafka-connector sink configuration + +Connector Description: To call Kamelets (indirectly) + +When using camel-kamelet-reify-kafka-connector as sink make sure to use the following Maven dependency to have support for the connector: + +[source,xml] +---- +<dependency> + <groupId>org.apache.camel.kafkaconnector</groupId> + <artifactId>camel-kamelet-reify-kafka-connector</artifactId> + <version>x.x.x</version> + <!-- use the same version as your Camel Kafka connector version --> +</dependency> +---- + +To use this Sink connector in Kafka connect you'll need to set the following connector.class + +[source,java] +---- +connector.class=org.apache.camel.kafkaconnector.kameletreify.CamelKameletreifySinkConnector +---- + + +The camel-kamelet-reify sink connector supports 4 options, which are listed below. + + + +[width="100%",cols="2,5,^1,1,1",options="header"] +|=== +| Name | Description | Default | Required | Priority +| *camel.sink.path.delegateUri* | The delegated uri | null | true | HIGH +| *camel.sink.endpoint.lazyStartProducer* | 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 cre [...] +| *camel.component.kamelet-reify.lazyStartProducer* | 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 processe [...] +| *camel.component.kamelet-reify.autowiredEnabled* | Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc. | true | false | MEDIUM +|=== + + + +The camel-kamelet-reify sink connector has no converters out of the box. + + + + + +The camel-kamelet-reify sink connector has no transforms out of the box. + + + + + +The camel-kamelet-reify sink connector has no aggregation strategies out of the box. + + + + +// kafka-connector options: END diff --git a/docs/modules/ROOT/pages/connectors/camel-kamelet-reify-kafka-source-connector.adoc b/docs/modules/ROOT/pages/connectors/camel-kamelet-reify-kafka-source-connector.adoc new file mode 100644 index 0000000..ec0d04d --- /dev/null +++ b/docs/modules/ROOT/pages/connectors/camel-kamelet-reify-kafka-source-connector.adoc @@ -0,0 +1,61 @@ +// kafka-connector options: START +[[camel-kamelet-reify-kafka-connector-source]] += camel-kamelet-reify-kafka-connector source configuration + +Connector description: To call Kamelets (indirectly) + +When using camel-kamelet-reify-kafka-connector as source make sure to use the following Maven dependency to have support for the connector: + +[source,xml] +---- +<dependency> + <groupId>org.apache.camel.kafkaconnector</groupId> + <artifactId>camel-kamelet-reify-kafka-connector</artifactId> + <version>x.x.x</version> + <!-- use the same version as your Camel Kafka connector version --> +</dependency> +---- + +To use this Source connector in Kafka connect you'll need to set the following connector.class + +[source,java] +---- +connector.class=org.apache.camel.kafkaconnector.kameletreify.CamelKameletreifySourceConnector +---- + + +The camel-kamelet-reify source connector supports 6 options, which are listed below. + + + +[width="100%",cols="2,5,^1,1,1",options="header"] +|=== +| Name | Description | Default | Required | Priority +| *camel.source.path.delegateUri* | The delegated uri | null | true | HIGH +| *camel.source.endpoint.bridgeErrorHandler* | 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 | false | MEDIUM +| *camel.source.endpoint.exceptionHandler* | To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with exceptions, that will be logged at WARN or ERROR level and ignored. | null | false | MEDIUM +| *camel.source.endpoint.exchangePattern* | Sets the exchange pattern when the consumer creates an exchange. One of: [InOnly] [InOut] [InOptionalOut] | null | false | MEDIUM +| *camel.component.kamelet-reify.bridgeErrorHandler* | 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 | false | MEDIUM +| *camel.component.kamelet-reify.autowiredEnabled* | Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc. | true | false | MEDIUM +|=== + + + +The camel-kamelet-reify source connector has no converters out of the box. + + + + + +The camel-kamelet-reify source connector has no transforms out of the box. + + + + + +The camel-kamelet-reify source connector has no aggregation strategies out of the box. + + + + +// kafka-connector options: END