You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by zb...@apache.org on 2022/10/07 07:27:32 UTC
[camel-quarkus] branch main updated: Add cloudEvents and knative extensions Fixes #3459
This is an automated email from the ASF dual-hosted git repository.
zbendhiba pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git
The following commit(s) were added to refs/heads/main by this push:
new 46197de96c Add cloudEvents and knative extensions Fixes #3459
46197de96c is described below
commit 46197de96cdc191bd5c342ee295fa085cafa752f
Author: Zineb Bendhiba <be...@gmail.com>
AuthorDate: Thu Jan 27 17:26:38 2022 +0100
Add cloudEvents and knative extensions
Fixes #3459
---
catalog/pom.xml | 52 ++++++
docs/modules/ROOT/examples/components/knative.yml | 13 ++
docs/modules/ROOT/examples/others/cloudevents.yml | 13 ++
docs/modules/ROOT/nav.adoc | 4 +
.../pages/reference/extensions/cloudevents.adoc | 45 ++++++
.../reference/extensions/knative-consumer.adoc | 38 +++++
.../reference/extensions/knative-producer.adoc | 38 +++++
.../ROOT/pages/reference/extensions/knative.adoc | 45 ++++++
extensions/cloudevents/deployment/pom.xml | 63 ++++++++
.../deployment/CloudeventsProcessor.java | 30 ++++
extensions/cloudevents/pom.xml | 39 +++++
extensions/cloudevents/runtime/pom.xml | 101 ++++++++++++
.../main/resources/META-INF/quarkus-extension.yaml | 31 ++++
extensions/knative-consumer/deployment/pom.xml | 60 +++++++
.../deployment/KnativeConsumerProcessor.java | 31 ++++
extensions/knative-consumer/pom.xml | 40 +++++
extensions/knative-consumer/runtime/pom.xml | 95 +++++++++++
.../main/resources/META-INF/quarkus-extension.yaml | 31 ++++
extensions/knative-producer/deployment/pom.xml | 61 +++++++
.../deployment/KnativeProducerProcessor.java | 30 ++++
extensions/knative-producer/pom.xml | 39 +++++
extensions/knative-producer/runtime/pom.xml | 94 +++++++++++
.../main/resources/META-INF/quarkus-extension.yaml | 31 ++++
extensions/knative/deployment/pom.xml | 71 +++++++++
.../knative/deployment/KnativeProcessor.java | 103 ++++++++++++
extensions/knative/pom.xml | 39 +++++
extensions/knative/runtime/pom.xml | 124 +++++++++++++++
.../component/knative/KnativeConsumerRecorder.java | 44 ++++++
.../component/knative/KnativeProducerRecorder.java | 46 ++++++
.../quarkus/component/knative/KnativeRecorder.java | 28 ++++
.../main/resources/META-INF/quarkus-extension.yaml | 31 ++++
extensions/pom.xml | 4 +
.../knative-channel-consumer/Readme.adoc | 8 +
integration-tests/knative-channel-consumer/pom.xml | 134 ++++++++++++++++
.../it/KnativeChannelConsumerResource.java | 37 +++++
.../component/knative/consumer/it/Route.java | 27 ++++
.../src/main/resources/application.properties | 21 +++
.../consumer/it/KnativeChannelConsumerIT.java | 23 +++
.../consumer/it/KnativeChannelConsumerTest.java | 60 +++++++
.../knative-endpoint-consumer/Readme.adoc | 8 +
.../knative-endpoint-consumer/pom.xml | 133 ++++++++++++++++
.../it/KnativeEndpointConsumerResource.java | 38 +++++
.../component/knative/consumer/it/Route.java | 28 ++++
.../src/src/main/resources/application.properties | 22 +++
.../consumer/it/KnativeEndpointConsumerIT.java | 23 +++
.../consumer/it/KnativeEndpointConsumerTest.java | 61 +++++++
.../knative-event-consumer/Readme.adoc | 11 ++
integration-tests/knative-event-consumer/pom.xml | 133 ++++++++++++++++
.../it/KnativeChannelConsumerResource.java | 38 +++++
.../component/knative/consumer/it/Route.java | 27 ++++
.../src/src/main/resources/application.properties | 21 +++
.../consumer/it/KnativeEventConsumerIT.java | 23 +++
.../consumer/it/KnativeEventConsumerTest.java | 63 ++++++++
integration-tests/knative-producer/Readme.adoc | 11 ++
integration-tests/knative-producer/pom.xml | 176 +++++++++++++++++++++
.../producer/it/KnativeProducerResource.java | 124 +++++++++++++++
.../component/knative/producer/it/Routes.java | 72 +++++++++
.../src/main/resources/application.properties | 40 +++++
.../knative/producer/it/KnativeProducerIT.java | 23 +++
.../knative/producer/it/KnativeProducerTest.java | 134 ++++++++++++++++
.../knative/producer/it/KnativeTestResource.java | 50 ++++++
.../src/test/resources/mappings/sendToBroker.json | 17 ++
.../src/test/resources/mappings/sendToChannel.json | 17 ++
.../src/test/resources/mappings/sendToService.json | 17 ++
integration-tests/knative/pom.xml | 114 +++++++++++++
.../component/knative/it/KnativeResource.java | 49 ++++++
.../quarkus/component/knative/it/KnativeIT.java | 24 +++
.../quarkus/component/knative/it/KnativeTest.java | 50 ++++++
integration-tests/pom.xml | 5 +
poms/bom/pom.xml | 60 +++++++
poms/bom/src/main/generated/flattened-full-pom.xml | 60 +++++++
.../src/main/generated/flattened-reduced-pom.xml | 60 +++++++
.../generated/flattened-reduced-verbose-pom.xml | 60 +++++++
tooling/scripts/test-categories.yaml | 5 +
74 files changed, 3621 insertions(+)
diff --git a/catalog/pom.xml b/catalog/pom.xml
index 0a93735b21..ed5466c69c 100644
--- a/catalog/pom.xml
+++ b/catalog/pom.xml
@@ -799,6 +799,19 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-cm-sms</artifactId>
@@ -2307,6 +2320,45 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-kotlin</artifactId>
diff --git a/docs/modules/ROOT/examples/components/knative.yml b/docs/modules/ROOT/examples/components/knative.yml
new file mode 100644
index 0000000000..bea771daa7
--- /dev/null
+++ b/docs/modules/ROOT/examples/components/knative.yml
@@ -0,0 +1,13 @@
+# Do not edit directly!
+# This file was generated by camel-quarkus-maven-plugin:update-extension-doc-page
+cqArtifactId: camel-quarkus-knative
+cqArtifactIdBase: knative
+cqNativeSupported: true
+cqStatus: Stable
+cqDeprecated: false
+cqJvmSince: 2.14.0
+cqNativeSince: 2.14.0
+cqCamelPartName: knative
+cqCamelPartTitle: Knative
+cqCamelPartDescription: Send and receive events from Knative.
+cqExtensionPageTitle: Knative
diff --git a/docs/modules/ROOT/examples/others/cloudevents.yml b/docs/modules/ROOT/examples/others/cloudevents.yml
new file mode 100644
index 0000000000..13f24b7e51
--- /dev/null
+++ b/docs/modules/ROOT/examples/others/cloudevents.yml
@@ -0,0 +1,13 @@
+# Do not edit directly!
+# This file was generated by camel-quarkus-maven-plugin:update-extension-doc-page
+cqArtifactId: camel-quarkus-cloudevents
+cqArtifactIdBase: cloudevents
+cqNativeSupported: true
+cqStatus: Stable
+cqDeprecated: false
+cqJvmSince: 2.14.0
+cqNativeSince: 2.14.0
+cqCamelPartName: cloudevents
+cqCamelPartTitle: Cloudevents
+cqCamelPartDescription: Camel support for the CloudEvents specification
+cqExtensionPageTitle: Cloudevents
diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc
index a47331d885..047ab3a667 100644
--- a/docs/modules/ROOT/nav.adoc
+++ b/docs/modules/ROOT/nav.adoc
@@ -86,6 +86,7 @@
*** xref:reference/extensions/chatscript.adoc[ChatScript]
*** xref:reference/extensions/chunk.adoc[Chunk]
*** xref:reference/extensions/core-cloud.adoc[Cloud]
+*** xref:reference/extensions/cloudevents.adoc[Cloudevents]
*** xref:reference/extensions/coap.adoc[CoAP]
*** xref:reference/extensions/cometd.adoc[CometD]
*** xref:reference/extensions/consul.adoc[Consul]
@@ -189,6 +190,9 @@
*** xref:reference/extensions/json-patch.adoc[JsonPatch]
*** xref:reference/extensions/kafka.adoc[Kafka]
*** xref:reference/extensions/kamelet.adoc[Kamelet]
+*** xref:reference/extensions/knative.adoc[Knative]
+*** xref:reference/extensions/knative-consumer.adoc[Knative Consumer]
+*** xref:reference/extensions/knative-producer.adoc[Knative Producer]
*** xref:reference/extensions/kotlin.adoc[Kotlin]
*** xref:reference/extensions/kotlin-dsl.adoc[Kotlin DSL]
*** xref:reference/extensions/kubernetes.adoc[Kubernetes]
diff --git a/docs/modules/ROOT/pages/reference/extensions/cloudevents.adoc b/docs/modules/ROOT/pages/reference/extensions/cloudevents.adoc
new file mode 100644
index 0000000000..2085d8ec9e
--- /dev/null
+++ b/docs/modules/ROOT/pages/reference/extensions/cloudevents.adoc
@@ -0,0 +1,45 @@
+// Do not edit directly!
+// This file was generated by camel-quarkus-maven-plugin:update-extension-doc-page
+[id="extensions-cloudevents"]
+= Cloudevents
+:linkattrs:
+:cq-artifact-id: camel-quarkus-cloudevents
+:cq-native-supported: true
+:cq-status: Stable
+:cq-status-deprecation: Stable
+:cq-description: Camel support for the CloudEvents specification
+:cq-deprecated: false
+:cq-jvm-since: 2.14.0
+:cq-native-since: 2.14.0
+
+ifeval::[{doc-show-badges} == true]
+[.badges]
+[.badge-key]##JVM since##[.badge-supported]##2.14.0## [.badge-key]##Native since##[.badge-supported]##2.14.0##
+endif::[]
+
+Camel support for the CloudEvents specification
+
+[id="extensions-cloudevents-whats-inside"]
+== What's inside
+
+* xref:{cq-camel-components}:others:cloudevents.adoc[Cloudevents]
+
+Please refer to the above link for usage and configuration details.
+
+[id="extensions-cloudevents-maven-coordinates"]
+== Maven coordinates
+
+https://{link-quarkus-code-generator}/?extension-search=camel-quarkus-cloudevents[Create a new project with this extension on {link-quarkus-code-generator}, window="_blank"]
+
+Or add the coordinates to your existing project:
+
+[source,xml]
+----
+<dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents</artifactId>
+</dependency>
+----
+ifeval::[{doc-show-user-guide-link} == true]
+Check the xref:user-guide/index.adoc[User guide] for more information about writing Camel Quarkus applications.
+endif::[]
diff --git a/docs/modules/ROOT/pages/reference/extensions/knative-consumer.adoc b/docs/modules/ROOT/pages/reference/extensions/knative-consumer.adoc
new file mode 100644
index 0000000000..37dff33e16
--- /dev/null
+++ b/docs/modules/ROOT/pages/reference/extensions/knative-consumer.adoc
@@ -0,0 +1,38 @@
+// Do not edit directly!
+// This file was generated by camel-quarkus-maven-plugin:update-extension-doc-page
+[id="extensions-knative-consumer"]
+= Knative Consumer
+:linkattrs:
+:cq-artifact-id: camel-quarkus-knative-consumer
+:cq-native-supported: true
+:cq-status: Stable
+:cq-status-deprecation: Stable
+:cq-description: Receives events from Knative
+:cq-deprecated: false
+:cq-jvm-since: 2.14.0
+:cq-native-since: 2.14.0
+
+ifeval::[{doc-show-badges} == true]
+[.badges]
+[.badge-key]##JVM since##[.badge-supported]##2.14.0## [.badge-key]##Native since##[.badge-supported]##2.14.0##
+endif::[]
+
+Receives events from Knative
+
+[id="extensions-knative-consumer-maven-coordinates"]
+== Maven coordinates
+
+https://{link-quarkus-code-generator}/?extension-search=camel-quarkus-knative-consumer[Create a new project with this extension on {link-quarkus-code-generator}, window="_blank"]
+
+Or add the coordinates to your existing project:
+
+[source,xml]
+----
+<dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+</dependency>
+----
+ifeval::[{doc-show-user-guide-link} == true]
+Check the xref:user-guide/index.adoc[User guide] for more information about writing Camel Quarkus applications.
+endif::[]
diff --git a/docs/modules/ROOT/pages/reference/extensions/knative-producer.adoc b/docs/modules/ROOT/pages/reference/extensions/knative-producer.adoc
new file mode 100644
index 0000000000..feadb25db1
--- /dev/null
+++ b/docs/modules/ROOT/pages/reference/extensions/knative-producer.adoc
@@ -0,0 +1,38 @@
+// Do not edit directly!
+// This file was generated by camel-quarkus-maven-plugin:update-extension-doc-page
+[id="extensions-knative-producer"]
+= Knative Producer
+:linkattrs:
+:cq-artifact-id: camel-quarkus-knative-producer
+:cq-native-supported: true
+:cq-status: Stable
+:cq-status-deprecation: Stable
+:cq-description: Sends events to Knative
+:cq-deprecated: false
+:cq-jvm-since: 2.14.0
+:cq-native-since: 2.14.0
+
+ifeval::[{doc-show-badges} == true]
+[.badges]
+[.badge-key]##JVM since##[.badge-supported]##2.14.0## [.badge-key]##Native since##[.badge-supported]##2.14.0##
+endif::[]
+
+Sends events to Knative
+
+[id="extensions-knative-producer-maven-coordinates"]
+== Maven coordinates
+
+https://{link-quarkus-code-generator}/?extension-search=camel-quarkus-knative-producer[Create a new project with this extension on {link-quarkus-code-generator}, window="_blank"]
+
+Or add the coordinates to your existing project:
+
+[source,xml]
+----
+<dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer</artifactId>
+</dependency>
+----
+ifeval::[{doc-show-user-guide-link} == true]
+Check the xref:user-guide/index.adoc[User guide] for more information about writing Camel Quarkus applications.
+endif::[]
diff --git a/docs/modules/ROOT/pages/reference/extensions/knative.adoc b/docs/modules/ROOT/pages/reference/extensions/knative.adoc
new file mode 100644
index 0000000000..5924b630cb
--- /dev/null
+++ b/docs/modules/ROOT/pages/reference/extensions/knative.adoc
@@ -0,0 +1,45 @@
+// Do not edit directly!
+// This file was generated by camel-quarkus-maven-plugin:update-extension-doc-page
+[id="extensions-knative"]
+= Knative
+:linkattrs:
+:cq-artifact-id: camel-quarkus-knative
+:cq-native-supported: true
+:cq-status: Stable
+:cq-status-deprecation: Stable
+:cq-description: Send and receive events from Knative.
+:cq-deprecated: false
+:cq-jvm-since: 2.14.0
+:cq-native-since: 2.14.0
+
+ifeval::[{doc-show-badges} == true]
+[.badges]
+[.badge-key]##JVM since##[.badge-supported]##2.14.0## [.badge-key]##Native since##[.badge-supported]##2.14.0##
+endif::[]
+
+Send and receive events from Knative.
+
+[id="extensions-knative-whats-inside"]
+== What's inside
+
+* xref:{cq-camel-components}::knative-component.adoc[Knative component], URI syntax: `knative:type/typeId`
+
+Please refer to the above link for usage and configuration details.
+
+[id="extensions-knative-maven-coordinates"]
+== Maven coordinates
+
+https://{link-quarkus-code-generator}/?extension-search=camel-quarkus-knative[Create a new project with this extension on {link-quarkus-code-generator}, window="_blank"]
+
+Or add the coordinates to your existing project:
+
+[source,xml]
+----
+<dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative</artifactId>
+</dependency>
+----
+ifeval::[{doc-show-user-guide-link} == true]
+Check the xref:user-guide/index.adoc[User guide] for more information about writing Camel Quarkus applications.
+endif::[]
diff --git a/extensions/cloudevents/deployment/pom.xml b/extensions/cloudevents/deployment/pom.xml
new file mode 100644
index 0000000000..87b3a2496f
--- /dev/null
+++ b/extensions/cloudevents/deployment/pom.xml
@@ -0,0 +1,63 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents-parent</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-cloudevents-deployment</artifactId>
+ <name>Camel Quarkus :: Cloudevents :: Deployment</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-core-deployment</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <annotationProcessorPaths>
+ <path>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-processor</artifactId>
+ <version>${quarkus.version}</version>
+ </path>
+ </annotationProcessorPaths>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
diff --git a/extensions/cloudevents/deployment/src/main/java/org/apache/camel/quarkus/component/cloudevents/deployment/CloudeventsProcessor.java b/extensions/cloudevents/deployment/src/main/java/org/apache/camel/quarkus/component/cloudevents/deployment/CloudeventsProcessor.java
new file mode 100644
index 0000000000..1c61bebe95
--- /dev/null
+++ b/extensions/cloudevents/deployment/src/main/java/org/apache/camel/quarkus/component/cloudevents/deployment/CloudeventsProcessor.java
@@ -0,0 +1,30 @@
+/*
+ * 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.quarkus.component.cloudevents.deployment;
+
+import io.quarkus.deployment.annotations.BuildStep;
+import io.quarkus.deployment.builditem.FeatureBuildItem;
+
+class CloudeventsProcessor {
+
+ private static final String FEATURE = "camel-cloudevents";
+
+ @BuildStep
+ FeatureBuildItem feature() {
+ return new FeatureBuildItem(FEATURE);
+ }
+}
diff --git a/extensions/cloudevents/pom.xml b/extensions/cloudevents/pom.xml
new file mode 100644
index 0000000000..40d23274f4
--- /dev/null
+++ b/extensions/cloudevents/pom.xml
@@ -0,0 +1,39 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-extensions</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-cloudevents-parent</artifactId>
+ <name>Camel Quarkus :: Cloudevents</name>
+ <packaging>pom</packaging>
+
+ <modules>
+ <module>deployment</module>
+ <module>runtime</module>
+ </modules>
+</project>
diff --git a/extensions/cloudevents/runtime/pom.xml b/extensions/cloudevents/runtime/pom.xml
new file mode 100644
index 0000000000..1e1a50714b
--- /dev/null
+++ b/extensions/cloudevents/runtime/pom.xml
@@ -0,0 +1,101 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents-parent</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-cloudevents</artifactId>
+ <name>Camel Quarkus :: Cloudevents :: Runtime</name>
+ <description>Camel support for the CloudEvents specification</description>
+
+ <properties>
+ <camel.quarkus.jvmSince>2.14.0</camel.quarkus.jvmSince>
+ <camel.quarkus.nativeSince>2.14.0</camel.quarkus.nativeSince>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-core</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-cloudevents</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-maven-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <annotationProcessorPaths>
+ <path>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-processor</artifactId>
+ <version>${quarkus.version}</version>
+ </path>
+ </annotationProcessorPaths>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+
+ <profiles>
+ <profile>
+ <id>full</id>
+ <activation>
+ <property>
+ <name>!quickly</name>
+ </property>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>update-extension-doc-page</id>
+ <goals>
+ <goal>update-extension-doc-page</goal>
+ </goals>
+ <phase>process-classes</phase>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+</project>
diff --git a/extensions/cloudevents/runtime/src/main/resources/META-INF/quarkus-extension.yaml b/extensions/cloudevents/runtime/src/main/resources/META-INF/quarkus-extension.yaml
new file mode 100644
index 0000000000..97617ca79d
--- /dev/null
+++ b/extensions/cloudevents/runtime/src/main/resources/META-INF/quarkus-extension.yaml
@@ -0,0 +1,31 @@
+#
+# 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.
+#
+
+# This is a generated file. Do not edit directly!
+# To re-generate, run the following command from the top level directory:
+#
+# mvn -N cq:update-quarkus-metadata
+#
+---
+name: "Camel Cloudevents"
+description: "Camel support for the CloudEvents specification"
+metadata:
+ guide: "https://camel.apache.org/camel-quarkus/latest/reference/extensions/cloudevents.html"
+ categories:
+ - "integration"
+ status:
+ - "stable"
diff --git a/extensions/knative-consumer/deployment/pom.xml b/extensions/knative-consumer/deployment/pom.xml
new file mode 100644
index 0000000000..8362848aea
--- /dev/null
+++ b/extensions/knative-consumer/deployment/pom.xml
@@ -0,0 +1,60 @@
+<?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">
+ <parent>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer-parent</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+
+ <artifactId>camel-quarkus-knative-consumer-deployment</artifactId>
+ <name>Camel Quarkus :: Knative Consumer :: Deployment</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-deployment</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <annotationProcessorPaths>
+ <path>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-processor</artifactId>
+ <version>${quarkus.version}</version>
+ </path>
+ </annotationProcessorPaths>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
diff --git a/extensions/knative-consumer/deployment/src/main/java/org/apache/camel/k/quarkus/knative/consumer/deployment/KnativeConsumerProcessor.java b/extensions/knative-consumer/deployment/src/main/java/org/apache/camel/k/quarkus/knative/consumer/deployment/KnativeConsumerProcessor.java
new file mode 100644
index 0000000000..0c00ab7121
--- /dev/null
+++ b/extensions/knative-consumer/deployment/src/main/java/org/apache/camel/k/quarkus/knative/consumer/deployment/KnativeConsumerProcessor.java
@@ -0,0 +1,31 @@
+/*
+ * 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.k.quarkus.knative.consumer.deployment;
+
+import io.quarkus.deployment.annotations.BuildStep;
+import io.quarkus.deployment.builditem.FeatureBuildItem;
+
+public class KnativeConsumerProcessor {
+
+ public static final String FEATURE = "camel-knative-consumer";
+
+ @BuildStep
+ FeatureBuildItem feature() {
+ return new FeatureBuildItem(FEATURE);
+ }
+
+}
diff --git a/extensions/knative-consumer/pom.xml b/extensions/knative-consumer/pom.xml
new file mode 100644
index 0000000000..a52edaab35
--- /dev/null
+++ b/extensions/knative-consumer/pom.xml
@@ -0,0 +1,40 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-extensions</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-knative-consumer-parent</artifactId>
+ <name>Camel Quarkus :: Knative Consumer</name>
+
+ <packaging>pom</packaging>
+
+ <modules>
+ <module>deployment</module>
+ <module>runtime</module>
+ </modules>
+
+
+</project>
diff --git a/extensions/knative-consumer/runtime/pom.xml b/extensions/knative-consumer/runtime/pom.xml
new file mode 100644
index 0000000000..946b5a1665
--- /dev/null
+++ b/extensions/knative-consumer/runtime/pom.xml
@@ -0,0 +1,95 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer-parent</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+ <name>Camel Quarkus :: Knative Consumer :: Runtime</name>
+ <description>Receives events from Knative</description>
+
+ <properties>
+ <camel.quarkus.jvmSince>2.14.0</camel.quarkus.jvmSince>
+ <camel.quarkus.nativeSince>2.14.0</camel.quarkus.nativeSince>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-maven-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <annotationProcessorPaths>
+ <path>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-processor</artifactId>
+ <version>${quarkus.version}</version>
+ </path>
+ </annotationProcessorPaths>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>full</id>
+ <activation>
+ <property>
+ <name>!quickly</name>
+ </property>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>update-extension-doc-page</id>
+ <goals>
+ <goal>update-extension-doc-page</goal>
+ </goals>
+ <phase>process-classes</phase>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+
+</project>
diff --git a/extensions/knative-consumer/runtime/src/main/resources/META-INF/quarkus-extension.yaml b/extensions/knative-consumer/runtime/src/main/resources/META-INF/quarkus-extension.yaml
new file mode 100644
index 0000000000..218289ece1
--- /dev/null
+++ b/extensions/knative-consumer/runtime/src/main/resources/META-INF/quarkus-extension.yaml
@@ -0,0 +1,31 @@
+#
+# 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.
+#
+
+# This is a generated file. Do not edit directly!
+# To re-generate, run the following command from the top level directory:
+#
+# mvn -N cq:update-quarkus-metadata
+#
+---
+name: "Camel Knative Consumer"
+description: "Receives events from Knative"
+metadata:
+ guide: "https://camel.apache.org/camel-quarkus/latest/reference/extensions/knative-consumer.html"
+ categories:
+ - "integration"
+ status:
+ - "stable"
diff --git a/extensions/knative-producer/deployment/pom.xml b/extensions/knative-producer/deployment/pom.xml
new file mode 100644
index 0000000000..7bf5946fc3
--- /dev/null
+++ b/extensions/knative-producer/deployment/pom.xml
@@ -0,0 +1,61 @@
+<?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">
+ <parent>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer-parent</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+
+ <artifactId>camel-quarkus-knative-producer-deployment</artifactId>
+ <name>Camel Quarkus :: Knative Producer :: Deployment</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-deployment</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <annotationProcessorPaths>
+ <path>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-processor</artifactId>
+ <version>${quarkus.version}</version>
+ </path>
+ </annotationProcessorPaths>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
diff --git a/extensions/knative-producer/deployment/src/main/java/org/apache/camel/k/quarkus/knative/producer/deployment/KnativeProducerProcessor.java b/extensions/knative-producer/deployment/src/main/java/org/apache/camel/k/quarkus/knative/producer/deployment/KnativeProducerProcessor.java
new file mode 100644
index 0000000000..46255b3063
--- /dev/null
+++ b/extensions/knative-producer/deployment/src/main/java/org/apache/camel/k/quarkus/knative/producer/deployment/KnativeProducerProcessor.java
@@ -0,0 +1,30 @@
+/*
+ * 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.k.quarkus.knative.producer.deployment;
+
+import io.quarkus.deployment.annotations.BuildStep;
+import io.quarkus.deployment.builditem.FeatureBuildItem;
+
+public class KnativeProducerProcessor {
+ public static final String FEATURE = "camel-knative-producer";
+
+ @BuildStep
+ FeatureBuildItem feature() {
+ return new FeatureBuildItem(FEATURE);
+ }
+
+}
diff --git a/extensions/knative-producer/pom.xml b/extensions/knative-producer/pom.xml
new file mode 100644
index 0000000000..fd0db3bdef
--- /dev/null
+++ b/extensions/knative-producer/pom.xml
@@ -0,0 +1,39 @@
+<?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">
+ <parent>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-extensions</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+
+ <artifactId>camel-quarkus-knative-producer-parent</artifactId>
+ <name>Camel Quarkus :: Knative Producer</name>
+
+ <packaging>pom</packaging>
+ <modules>
+ <module>deployment</module>
+ <module>runtime</module>
+ </modules>
+
+
+</project>
diff --git a/extensions/knative-producer/runtime/pom.xml b/extensions/knative-producer/runtime/pom.xml
new file mode 100644
index 0000000000..8164780309
--- /dev/null
+++ b/extensions/knative-producer/runtime/pom.xml
@@ -0,0 +1,94 @@
+<?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">
+ <parent>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer-parent</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+
+ <artifactId>camel-quarkus-knative-producer</artifactId>
+ <name>Camel Quarkus :: Knative Producer :: Runtime</name>
+ <description>Sends events to Knative</description>
+
+ <properties>
+ <camel.quarkus.jvmSince>2.14.0</camel.quarkus.jvmSince>
+ <camel.quarkus.nativeSince>2.14.0</camel.quarkus.nativeSince>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-maven-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <annotationProcessorPaths>
+ <path>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-processor</artifactId>
+ <version>${quarkus.version}</version>
+ </path>
+ </annotationProcessorPaths>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>full</id>
+ <activation>
+ <property>
+ <name>!quickly</name>
+ </property>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>update-extension-doc-page</id>
+ <goals>
+ <goal>update-extension-doc-page</goal>
+ </goals>
+ <phase>process-classes</phase>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+</project>
diff --git a/extensions/knative-producer/runtime/src/main/resources/META-INF/quarkus-extension.yaml b/extensions/knative-producer/runtime/src/main/resources/META-INF/quarkus-extension.yaml
new file mode 100644
index 0000000000..4a39659647
--- /dev/null
+++ b/extensions/knative-producer/runtime/src/main/resources/META-INF/quarkus-extension.yaml
@@ -0,0 +1,31 @@
+#
+# 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.
+#
+
+# This is a generated file. Do not edit directly!
+# To re-generate, run the following command from the top level directory:
+#
+# mvn -N cq:update-quarkus-metadata
+#
+---
+name: "Camel Knative Producer"
+description: "Sends events to Knative"
+metadata:
+ guide: "https://camel.apache.org/camel-quarkus/latest/reference/extensions/knative-producer.html"
+ categories:
+ - "integration"
+ status:
+ - "stable"
diff --git a/extensions/knative/deployment/pom.xml b/extensions/knative/deployment/pom.xml
new file mode 100644
index 0000000000..70352e55ac
--- /dev/null
+++ b/extensions/knative/deployment/pom.xml
@@ -0,0 +1,71 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-parent</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-knative-deployment</artifactId>
+ <name>Camel Quarkus :: Knative :: Deployment</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-core-deployment</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents-deployment</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-vertx-http-deployment</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <annotationProcessorPaths>
+ <path>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-processor</artifactId>
+ <version>${quarkus.version}</version>
+ </path>
+ </annotationProcessorPaths>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
diff --git a/extensions/knative/deployment/src/main/java/org/apache/camel/quarkus/component/knative/deployment/KnativeProcessor.java b/extensions/knative/deployment/src/main/java/org/apache/camel/quarkus/component/knative/deployment/KnativeProcessor.java
new file mode 100644
index 0000000000..318087d1c7
--- /dev/null
+++ b/extensions/knative/deployment/src/main/java/org/apache/camel/quarkus/component/knative/deployment/KnativeProcessor.java
@@ -0,0 +1,103 @@
+/*
+ * 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.quarkus.component.knative.deployment;
+
+import java.util.List;
+
+import io.quarkus.arc.deployment.UnremovableBeanBuildItem;
+import io.quarkus.deployment.annotations.BuildStep;
+import io.quarkus.deployment.annotations.ExecutionTime;
+import io.quarkus.deployment.annotations.Record;
+import io.quarkus.deployment.builditem.FeatureBuildItem;
+import io.quarkus.deployment.builditem.nativeimage.ReflectiveClassBuildItem;
+import io.quarkus.vertx.core.deployment.CoreVertxBuildItem;
+import io.quarkus.vertx.http.deployment.VertxWebRouterBuildItem;
+import org.apache.camel.component.knative.KnativeComponent;
+import org.apache.camel.component.knative.KnativeConstants;
+import org.apache.camel.component.knative.spi.KnativeEnvironment;
+import org.apache.camel.component.knative.spi.KnativeResource;
+import org.apache.camel.quarkus.component.knative.KnativeConsumerRecorder;
+import org.apache.camel.quarkus.component.knative.KnativeProducerRecorder;
+import org.apache.camel.quarkus.component.knative.KnativeRecorder;
+import org.apache.camel.quarkus.core.deployment.spi.CamelRuntimeBeanBuildItem;
+import org.apache.camel.quarkus.core.deployment.spi.CamelServiceFilter;
+import org.apache.camel.quarkus.core.deployment.spi.CamelServiceFilterBuildItem;
+import org.apache.camel.spi.ComponentCustomizer;
+
+class KnativeProcessor {
+
+ private static final String FEATURE = "camel-knative";
+
+ @BuildStep
+ FeatureBuildItem feature() {
+ return new FeatureBuildItem(FEATURE);
+ }
+
+ @BuildStep
+ List<UnremovableBeanBuildItem> unremovableBeans() {
+ return List.of(
+ UnremovableBeanBuildItem.beanTypes(KnativeEnvironment.class));
+ }
+
+ @BuildStep
+ List<ReflectiveClassBuildItem> reflectiveClasses() {
+ return List.of(
+ new ReflectiveClassBuildItem(true, false, KnativeEnvironment.class),
+ new ReflectiveClassBuildItem(true, false, KnativeResource.class));
+ }
+
+ @BuildStep
+ List<CamelServiceFilterBuildItem> servicesFilters() {
+ return List.of(
+ new CamelServiceFilterBuildItem(CamelServiceFilter.forComponent(KnativeConstants.SCHEME)),
+ new CamelServiceFilterBuildItem(CamelServiceFilter
+ .forPathEndingWith(CamelServiceFilter.CAMEL_SERVICE_BASE_PATH + "/knative/transport/http")));
+ }
+
+ @Record(ExecutionTime.RUNTIME_INIT)
+ @BuildStep
+ CamelRuntimeBeanBuildItem knativeComponent(KnativeRecorder recorder) {
+ return new CamelRuntimeBeanBuildItem(
+ KnativeConstants.SCHEME,
+ KnativeComponent.class.getName(),
+ recorder.createKnativeComponent());
+ }
+
+ @Record(ExecutionTime.RUNTIME_INIT)
+ @BuildStep
+ CamelRuntimeBeanBuildItem knativeConsumerCustomizer(
+ KnativeConsumerRecorder recorder,
+ VertxWebRouterBuildItem router) {
+
+ return new CamelRuntimeBeanBuildItem(
+ FEATURE + "-consumer-customizer",
+ ComponentCustomizer.class.getName(),
+ recorder.createKnativeConsumerFactoryCustomizer(router.getHttpRouter()));
+ }
+
+ @Record(ExecutionTime.RUNTIME_INIT)
+ @BuildStep
+ CamelRuntimeBeanBuildItem knativeProducerCustomizer(
+ KnativeProducerRecorder recorder,
+ CoreVertxBuildItem vertx) {
+
+ return new CamelRuntimeBeanBuildItem(
+ FEATURE + "-producer-customizer",
+ ComponentCustomizer.class.getName(),
+ recorder.createKnativeProducerFactoryCustomizer(vertx.getVertx()));
+ }
+}
diff --git a/extensions/knative/pom.xml b/extensions/knative/pom.xml
new file mode 100644
index 0000000000..87a12c23c7
--- /dev/null
+++ b/extensions/knative/pom.xml
@@ -0,0 +1,39 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-extensions</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-knative-parent</artifactId>
+ <name>Camel Quarkus :: Knative</name>
+ <packaging>pom</packaging>
+
+ <modules>
+ <module>deployment</module>
+ <module>runtime</module>
+ </modules>
+</project>
diff --git a/extensions/knative/runtime/pom.xml b/extensions/knative/runtime/pom.xml
new file mode 100644
index 0000000000..b583d61759
--- /dev/null
+++ b/extensions/knative/runtime/pom.xml
@@ -0,0 +1,124 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-parent</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-knative</artifactId>
+ <name>Camel Quarkus :: Knative :: Runtime</name>
+ <description>Send and receive events from Knative.</description>
+
+ <properties>
+ <camel.quarkus.jvmSince>2.14.0</camel.quarkus.jvmSince>
+ <camel.quarkus.nativeSince>2.14.0</camel.quarkus.nativeSince>
+ </properties>
+
+ <dependencyManagement>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-bom</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>import</scope>
+ </dependency>
+ </dependencies>
+ </dependencyManagement>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-core</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-knative</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-knative-http</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-vertx-http</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-maven-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <annotationProcessorPaths>
+ <path>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-extension-processor</artifactId>
+ <version>${quarkus.version}</version>
+ </path>
+ </annotationProcessorPaths>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>full</id>
+ <activation>
+ <property>
+ <name>!quickly</name>
+ </property>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>update-extension-doc-page</id>
+ <goals>
+ <goal>update-extension-doc-page</goal>
+ </goals>
+ <phase>process-classes</phase>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+</project>
diff --git a/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeConsumerRecorder.java b/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeConsumerRecorder.java
new file mode 100644
index 0000000000..4ec990df53
--- /dev/null
+++ b/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeConsumerRecorder.java
@@ -0,0 +1,44 @@
+/*
+ * 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.quarkus.component.knative;
+
+import io.quarkus.runtime.RuntimeValue;
+import io.quarkus.runtime.annotations.Recorder;
+import io.vertx.ext.web.Router;
+import org.apache.camel.Component;
+import org.apache.camel.component.knative.KnativeComponent;
+import org.apache.camel.component.knative.http.KnativeHttpConsumerFactory;
+import org.apache.camel.spi.ComponentCustomizer;
+
+@Recorder
+public class KnativeConsumerRecorder {
+ public RuntimeValue<ComponentCustomizer> createKnativeConsumerFactoryCustomizer(RuntimeValue<Router> router) {
+ KnativeHttpConsumerFactory factory = new KnativeHttpConsumerFactory();
+ factory.setRouter(router.getValue());
+
+ ComponentCustomizer cf = new ComponentCustomizer() {
+ @Override
+ public void configure(String name, Component target) {
+ if (target instanceof KnativeComponent) {
+ ((KnativeComponent) target).setConsumerFactory(factory);
+ }
+ }
+ };
+
+ return new RuntimeValue<>(cf);
+ }
+}
diff --git a/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeProducerRecorder.java b/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeProducerRecorder.java
new file mode 100644
index 0000000000..ef173795f4
--- /dev/null
+++ b/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeProducerRecorder.java
@@ -0,0 +1,46 @@
+/*
+ * 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.quarkus.component.knative;
+
+import java.util.function.Supplier;
+
+import io.quarkus.runtime.RuntimeValue;
+import io.quarkus.runtime.annotations.Recorder;
+import io.vertx.core.Vertx;
+import org.apache.camel.Component;
+import org.apache.camel.component.knative.KnativeComponent;
+import org.apache.camel.component.knative.http.KnativeHttpProducerFactory;
+import org.apache.camel.spi.ComponentCustomizer;
+
+@Recorder
+public class KnativeProducerRecorder {
+ public RuntimeValue<ComponentCustomizer> createKnativeProducerFactoryCustomizer(Supplier<Vertx> vertx) {
+ KnativeHttpProducerFactory factory = new KnativeHttpProducerFactory();
+ factory.setVertx(vertx.get());
+
+ ComponentCustomizer cf = new ComponentCustomizer() {
+ @Override
+ public void configure(String name, Component target) {
+ if (target instanceof KnativeComponent) {
+ ((KnativeComponent) target).setProducerFactory(factory);
+ }
+ }
+ };
+
+ return new RuntimeValue<>(cf);
+ }
+}
diff --git a/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeRecorder.java b/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeRecorder.java
new file mode 100644
index 0000000000..67ce910a37
--- /dev/null
+++ b/extensions/knative/runtime/src/main/java/org/apache/camel/quarkus/component/knative/KnativeRecorder.java
@@ -0,0 +1,28 @@
+/*
+ * 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.quarkus.component.knative;
+
+import io.quarkus.runtime.RuntimeValue;
+import io.quarkus.runtime.annotations.Recorder;
+import org.apache.camel.component.knative.KnativeComponent;
+
+@Recorder
+public class KnativeRecorder {
+ public RuntimeValue<KnativeComponent> createKnativeComponent() {
+ return new RuntimeValue<>(new KnativeComponent());
+ }
+}
diff --git a/extensions/knative/runtime/src/main/resources/META-INF/quarkus-extension.yaml b/extensions/knative/runtime/src/main/resources/META-INF/quarkus-extension.yaml
new file mode 100644
index 0000000000..bed9d035fa
--- /dev/null
+++ b/extensions/knative/runtime/src/main/resources/META-INF/quarkus-extension.yaml
@@ -0,0 +1,31 @@
+#
+# 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.
+#
+
+# This is a generated file. Do not edit directly!
+# To re-generate, run the following command from the top level directory:
+#
+# mvn -N cq:update-quarkus-metadata
+#
+---
+name: "Camel Knative"
+description: "Send and receive events from Knative"
+metadata:
+ guide: "https://camel.apache.org/camel-quarkus/latest/reference/extensions/knative.html"
+ categories:
+ - "integration"
+ status:
+ - "stable"
diff --git a/extensions/pom.xml b/extensions/pom.xml
index 9aef75d7d5..7150e05cbc 100644
--- a/extensions/pom.xml
+++ b/extensions/pom.xml
@@ -75,6 +75,7 @@
<module>caffeine</module>
<module>cassandraql</module>
<module>cbor</module>
+ <module>cloudevents</module>
<module>consul</module>
<module>controlbus</module>
<module>couchdb</module>
@@ -149,6 +150,9 @@
<module>jta</module>
<module>kafka</module>
<module>kamelet</module>
+ <module>knative</module>
+ <module>knative-consumer</module>
+ <module>knative-producer</module>
<module>kotlin</module>
<module>kubernetes</module>
<module>kudu</module>
diff --git a/integration-tests/knative-channel-consumer/Readme.adoc b/integration-tests/knative-channel-consumer/Readme.adoc
new file mode 100644
index 0000000000..9eaa64af5d
--- /dev/null
+++ b/integration-tests/knative-channel-consumer/Readme.adoc
@@ -0,0 +1,8 @@
+= Knative Channel Consumer tests
+
+These integration tests the HTTP routes only.
+
+If you wish to test this application in real Knative environment, follow the next steps.
+* Create an InMemory Knative Channel named `channel-test`
+* Deploy the app https://quarkus.io/guides/deploying-to-kubernetes#knative[as a Serverless deployment].
+* Send CloudEvents to the channel.
diff --git a/integration-tests/knative-channel-consumer/pom.xml b/integration-tests/knative-channel-consumer/pom.xml
new file mode 100644
index 0000000000..465b6e042b
--- /dev/null
+++ b/integration-tests/knative-channel-consumer/pom.xml
@@ -0,0 +1,134 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-build-parent-it</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../../poms/build-parent-it/pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-integration-test-knative-channel-consumer</artifactId>
+ <name>Camel Quarkus :: Integration Tests :: Knative Consumer</name>
+ <description>Integration tests for Camel Quarkus Knative Consumer extension - Channel consumer</description>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-seda</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-resteasy</artifactId>
+ </dependency>
+
+ <!-- test dependencies -->
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-junit5</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>io.rest-assured</groupId>
+ <artifactId>rest-assured</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.awaitility</groupId>
+ <artifactId>awaitility</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <profiles>
+ <profile>
+ <id>native</id>
+ <activation>
+ <property>
+ <name>native</name>
+ </property>
+ </activation>
+ <properties>
+ <quarkus.package.type>native</quarkus.package.type>
+ </properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-failsafe-plugin</artifactId>
+ <executions>
+ <execution>
+ <goals>
+ <goal>integration-test</goal>
+ <goal>verify</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>virtualDependencies</id>
+ <activation>
+ <property>
+ <name>!noVirtualDependencies</name>
+ </property>
+ </activation>
+ <dependencies>
+ <!-- The following dependencies guarantee that this module is built after them. You can update them by running `mvn process-resources -Pformat -N` from the source tree root directory -->
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-seda-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ </dependencies>
+ </profile>
+ </profiles>
+
+</project>
\ No newline at end of file
diff --git a/integration-tests/knative-channel-consumer/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerResource.java b/integration-tests/knative-channel-consumer/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerResource.java
new file mode 100644
index 0000000000..19ae90c2d3
--- /dev/null
+++ b/integration-tests/knative-channel-consumer/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerResource.java
@@ -0,0 +1,37 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import javax.enterprise.context.ApplicationScoped;
+import javax.inject.Inject;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+
+import org.apache.camel.ConsumerTemplate;
+
+@Path("/knative-channel-consumer")
+@ApplicationScoped
+public class KnativeChannelConsumerResource {
+ @Inject
+ ConsumerTemplate consumerTemplate;
+
+ @GET
+ public String readReceivedMessages() {
+ return consumerTemplate.receiveBody("seda:queue-channel", 1000, String.class);
+ }
+
+}
diff --git a/integration-tests/knative-channel-consumer/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java b/integration-tests/knative-channel-consumer/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java
new file mode 100644
index 0000000000..4bc9efec8a
--- /dev/null
+++ b/integration-tests/knative-channel-consumer/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java
@@ -0,0 +1,27 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import org.apache.camel.builder.RouteBuilder;
+
+public class Route extends RouteBuilder {
+ @Override
+ public void configure() throws Exception {
+ from("knative:channel/channel-test")
+ .to("seda:queue-channel");
+ }
+}
diff --git a/integration-tests/knative-channel-consumer/src/main/resources/application.properties b/integration-tests/knative-channel-consumer/src/main/resources/application.properties
new file mode 100644
index 0000000000..e5124a339b
--- /dev/null
+++ b/integration-tests/knative-channel-consumer/src/main/resources/application.properties
@@ -0,0 +1,21 @@
+## ---------------------------------------------------------------------------
+## 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.
+## ---------------------------------------------------------------------------
+
+# channel configuration
+camel.component.knative.environment.resources[0].name = channel-test
+camel.component.knative.environment.resources[0].type = channel
+camel.component.knative.environment.resources[0].endpoint-kind = source
\ No newline at end of file
diff --git a/integration-tests/knative-channel-consumer/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerIT.java b/integration-tests/knative-channel-consumer/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerIT.java
new file mode 100644
index 0000000000..14040a76f8
--- /dev/null
+++ b/integration-tests/knative-channel-consumer/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerIT.java
@@ -0,0 +1,23 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import io.quarkus.test.junit.QuarkusIntegrationTest;
+
+@QuarkusIntegrationTest
+public class KnativeChannelConsumerIT extends KnativeChannelConsumerTest {
+}
diff --git a/integration-tests/knative-channel-consumer/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerTest.java b/integration-tests/knative-channel-consumer/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerTest.java
new file mode 100644
index 0000000000..2aa353422d
--- /dev/null
+++ b/integration-tests/knative-channel-consumer/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerTest.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.quarkus.component.knative.consumer.it;
+
+import java.util.UUID;
+import java.util.concurrent.TimeUnit;
+
+import javax.ws.rs.core.MediaType;
+
+import io.quarkus.test.junit.QuarkusTest;
+import org.apache.camel.component.cloudevents.CloudEvents;
+import org.awaitility.Awaitility;
+import org.junit.jupiter.api.Test;
+
+import static io.restassured.RestAssured.given;
+
+@QuarkusTest
+public class KnativeChannelConsumerTest {
+
+ @Test
+ void consumeEventsFromChannel() {
+ // consume from channel
+ given()
+ .contentType(MediaType.TEXT_PLAIN)
+ .accept(MediaType.APPLICATION_JSON)
+ .header("ce-specversion", CloudEvents.v1_0.version())
+ .header("ce-id", UUID.randomUUID())
+ .header("ce-time", "2018-04-05T17:31:00Z")
+ .header("ce-source", "camel-channel-test")
+ .body("Hello World - Testing Knative Channel Camel consumer")
+ .when()
+ .post("/")
+ .then()
+ .statusCode(200);
+
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/knative-channel-consumer")
+ .then()
+ .extract().body().asString();
+ return body != null && body.contains("Hello World - Testing Knative Channel Camel consumer");
+ });
+
+ }
+
+}
diff --git a/integration-tests/knative-endpoint-consumer/Readme.adoc b/integration-tests/knative-endpoint-consumer/Readme.adoc
new file mode 100644
index 0000000000..24630a99dd
--- /dev/null
+++ b/integration-tests/knative-endpoint-consumer/Readme.adoc
@@ -0,0 +1,8 @@
+= Knative Endpoint Consumer tests
+
+These integration tests the HTTP routes only.
+
+If you wish to test this application in real Knative environment, follow the next steps.
+
+* Deploy the app https://knative.dev/docs/getting-started/first-service/[as a Knative Service] named `endpoint-test`.
+* Send CloudEvents to the URL of the service.
diff --git a/integration-tests/knative-endpoint-consumer/pom.xml b/integration-tests/knative-endpoint-consumer/pom.xml
new file mode 100644
index 0000000000..97bd673e15
--- /dev/null
+++ b/integration-tests/knative-endpoint-consumer/pom.xml
@@ -0,0 +1,133 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-build-parent-it</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../../poms/build-parent-it/pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-integration-test-knative-endpoint-consumer</artifactId>
+ <name>Camel Quarkus :: Integration Tests :: Knative Consumer</name>
+ <description>Integration tests for Camel Quarkus Knative Consumer extension - Endpoint consumer</description>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-seda</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-resteasy</artifactId>
+ </dependency>
+ <!-- test dependencies -->
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-junit5</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>io.rest-assured</groupId>
+ <artifactId>rest-assured</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.awaitility</groupId>
+ <artifactId>awaitility</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <profiles>
+ <profile>
+ <id>native</id>
+ <activation>
+ <property>
+ <name>native</name>
+ </property>
+ </activation>
+ <properties>
+ <quarkus.package.type>native</quarkus.package.type>
+ </properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-failsafe-plugin</artifactId>
+ <executions>
+ <execution>
+ <goals>
+ <goal>integration-test</goal>
+ <goal>verify</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>virtualDependencies</id>
+ <activation>
+ <property>
+ <name>!noVirtualDependencies</name>
+ </property>
+ </activation>
+ <dependencies>
+ <!-- The following dependencies guarantee that this module is built after them. You can update them by running `mvn process-resources -Pformat -N` from the source tree root directory -->
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-seda-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ </dependencies>
+ </profile>
+ </profiles>
+
+</project>
\ No newline at end of file
diff --git a/integration-tests/knative-endpoint-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerResource.java b/integration-tests/knative-endpoint-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerResource.java
new file mode 100644
index 0000000000..1f2a2b91c3
--- /dev/null
+++ b/integration-tests/knative-endpoint-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerResource.java
@@ -0,0 +1,38 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import javax.enterprise.context.ApplicationScoped;
+import javax.inject.Inject;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.PathParam;
+
+import org.apache.camel.ConsumerTemplate;
+
+@Path("/knative-endpoint-consumer")
+@ApplicationScoped
+public class KnativeEndpointConsumerResource {
+ @Inject
+ ConsumerTemplate consumerTemplate;
+
+ @GET
+ public String readReceivedMessages() {
+ return consumerTemplate.receiveBody("seda:queue-endpoint", 1000, String.class);
+ }
+
+}
diff --git a/integration-tests/knative-endpoint-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java b/integration-tests/knative-endpoint-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java
new file mode 100644
index 0000000000..ee888b3328
--- /dev/null
+++ b/integration-tests/knative-endpoint-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java
@@ -0,0 +1,28 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import org.apache.camel.builder.RouteBuilder;
+
+public class Route extends RouteBuilder {
+ @Override
+ public void configure() throws Exception {
+ from("knative:endpoint/endpoint-test")
+ .to("seda:queue-endpoint");
+
+ }
+}
diff --git a/integration-tests/knative-endpoint-consumer/src/src/main/resources/application.properties b/integration-tests/knative-endpoint-consumer/src/src/main/resources/application.properties
new file mode 100644
index 0000000000..f281894463
--- /dev/null
+++ b/integration-tests/knative-endpoint-consumer/src/src/main/resources/application.properties
@@ -0,0 +1,22 @@
+## ---------------------------------------------------------------------------
+## 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.
+## ---------------------------------------------------------------------------
+
+# endpoint configuration
+camel.component.knative.environment.resources[0].name = endpoint-test
+camel.component.knative.environment.resources[0].type = endpoint
+camel.component.knative.environment.resources[0].endpoint-kind = source
+camel.component.knative.environment.resources[0].path = /my-endpoint
\ No newline at end of file
diff --git a/integration-tests/knative-endpoint-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerIT.java b/integration-tests/knative-endpoint-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerIT.java
new file mode 100644
index 0000000000..a9cd6118e2
--- /dev/null
+++ b/integration-tests/knative-endpoint-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerIT.java
@@ -0,0 +1,23 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import io.quarkus.test.junit.QuarkusIntegrationTest;
+
+@QuarkusIntegrationTest
+public class KnativeEndpointConsumerIT extends org.apache.camel.quarkus.component.knative.consumer.it.KnativeEndpointConsumerTest {
+}
diff --git a/integration-tests/knative-endpoint-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerTest.java b/integration-tests/knative-endpoint-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerTest.java
new file mode 100644
index 0000000000..c91d37340e
--- /dev/null
+++ b/integration-tests/knative-endpoint-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEndpointConsumerTest.java
@@ -0,0 +1,61 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import java.util.UUID;
+import java.util.concurrent.TimeUnit;
+
+import javax.ws.rs.core.MediaType;
+
+import io.quarkus.test.common.http.TestHTTPEndpoint;
+import io.quarkus.test.junit.QuarkusTest;
+import io.restassured.path.json.JsonPath;
+import org.apache.camel.component.cloudevents.CloudEvents;
+import org.apache.camel.component.knative.http.KnativeHttpConsumerFactory;
+import org.awaitility.Awaitility;
+import org.junit.jupiter.api.Test;
+
+import static io.restassured.RestAssured.given;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+@QuarkusTest
+public class KnativeEndpointConsumerTest {
+ @Test
+ void consumeFromCamelService() {
+ given()
+ .contentType(MediaType.TEXT_PLAIN)
+ .accept(MediaType.TEXT_PLAIN)
+ .header("ce-specversion", CloudEvents.v1_0.version())
+ .header("ce-id", UUID.randomUUID())
+ .header("ce-time", "2018-04-05T17:31:00Z")
+ .header("ce-source", "camel-endpoint-test")
+ .body("Hello World - Testing Knative Services Camel consumer")
+ .when()
+ .post("/my-endpoint")
+ .then()
+ .statusCode(200);
+
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/")
+ .then()
+ .extract().body().asString();
+ return body != null && body.contains("Hello World - Testing Knative Services Camel consumer");
+ });
+ }
+
+}
diff --git a/integration-tests/knative-event-consumer/Readme.adoc b/integration-tests/knative-event-consumer/Readme.adoc
new file mode 100644
index 0000000000..deb83cd84a
--- /dev/null
+++ b/integration-tests/knative-event-consumer/Readme.adoc
@@ -0,0 +1,11 @@
+= Knative Event Consumer tests
+
+These integration tests the HTTP routes only.
+
+If you wish to test this application in real Knative environment, follow the next steps.
+
+* Create an InMemory Knative Broker named `broker-test`
+* Deploy the app https://quarkus.io/guides/deploying-to-kubernetes#knative[as a Serverless deployment]
+* Send CloudEvents to the broker.
+
+
diff --git a/integration-tests/knative-event-consumer/pom.xml b/integration-tests/knative-event-consumer/pom.xml
new file mode 100644
index 0000000000..6335aa8266
--- /dev/null
+++ b/integration-tests/knative-event-consumer/pom.xml
@@ -0,0 +1,133 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-build-parent-it</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../../poms/build-parent-it/pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-integration-test-knative-event-consumer</artifactId>
+ <name>Camel Quarkus :: Integration Tests :: Knative Consumer Event</name>
+ <description>Integration tests for Camel Quarkus Knative Consumer extension - Consuming events</description>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-seda</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-resteasy</artifactId>
+ </dependency>
+ <!-- test dependencies -->
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-junit5</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>io.rest-assured</groupId>
+ <artifactId>rest-assured</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.awaitility</groupId>
+ <artifactId>awaitility</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <profiles>
+ <profile>
+ <id>native</id>
+ <activation>
+ <property>
+ <name>native</name>
+ </property>
+ </activation>
+ <properties>
+ <quarkus.package.type>native</quarkus.package.type>
+ </properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-failsafe-plugin</artifactId>
+ <executions>
+ <execution>
+ <goals>
+ <goal>integration-test</goal>
+ <goal>verify</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>virtualDependencies</id>
+ <activation>
+ <property>
+ <name>!noVirtualDependencies</name>
+ </property>
+ </activation>
+ <dependencies>
+ <!-- The following dependencies guarantee that this module is built after them. You can update them by running `mvn process-resources -Pformat -N` from the source tree root directory -->
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-seda-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ </dependencies>
+ </profile>
+ </profiles>
+
+</project>
\ No newline at end of file
diff --git a/integration-tests/knative-event-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerResource.java b/integration-tests/knative-event-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerResource.java
new file mode 100644
index 0000000000..c863f967ed
--- /dev/null
+++ b/integration-tests/knative-event-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeChannelConsumerResource.java
@@ -0,0 +1,38 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import javax.enterprise.context.ApplicationScoped;
+import javax.inject.Inject;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.PathParam;
+
+import org.apache.camel.ConsumerTemplate;
+
+@Path("/knative-channel-consumer")
+@ApplicationScoped
+public class KnativeChannelConsumerResource {
+ @Inject
+ ConsumerTemplate consumerTemplate;
+
+ @GET
+ public String readReceivedMessages() {
+ return consumerTemplate.receiveBody("seda:queue-event", 1000, String.class);
+ }
+
+}
diff --git a/integration-tests/knative-event-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java b/integration-tests/knative-event-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java
new file mode 100644
index 0000000000..721248a5fd
--- /dev/null
+++ b/integration-tests/knative-event-consumer/src/src/main/java/org/apache/camel/quarkus/component/knative/consumer/it/Route.java
@@ -0,0 +1,27 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import org.apache.camel.builder.RouteBuilder;
+
+public class Route extends RouteBuilder {
+ @Override
+ public void configure() throws Exception {
+ from("knative:event/event-test?reply=false")
+ .to("seda:queue-event");
+ }
+}
diff --git a/integration-tests/knative-event-consumer/src/src/main/resources/application.properties b/integration-tests/knative-event-consumer/src/src/main/resources/application.properties
new file mode 100644
index 0000000000..3a4c8d6ec0
--- /dev/null
+++ b/integration-tests/knative-event-consumer/src/src/main/resources/application.properties
@@ -0,0 +1,21 @@
+## ---------------------------------------------------------------------------
+## 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.
+## ---------------------------------------------------------------------------
+
+# event configuration
+camel.component.knative.environment.resources[0].name = event-test
+camel.component.knative.environment.resources[0].type = event
+camel.component.knative.environment.resources[0].endpoint-kind = source
diff --git a/integration-tests/knative-event-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEventConsumerIT.java b/integration-tests/knative-event-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEventConsumerIT.java
new file mode 100644
index 0000000000..0148488373
--- /dev/null
+++ b/integration-tests/knative-event-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEventConsumerIT.java
@@ -0,0 +1,23 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import io.quarkus.test.junit.QuarkusIntegrationTest;
+
+@QuarkusIntegrationTest
+public class KnativeEventConsumerIT extends org.apache.camel.quarkus.component.knative.consumer.it.KnativeEventConsumerTest {
+}
diff --git a/integration-tests/knative-event-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEventConsumerTest.java b/integration-tests/knative-event-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEventConsumerTest.java
new file mode 100644
index 0000000000..b83f51ba33
--- /dev/null
+++ b/integration-tests/knative-event-consumer/src/src/test/java/org/apache/camel/quarkus/component/knative/consumer/it/KnativeEventConsumerTest.java
@@ -0,0 +1,63 @@
+/*
+ * 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.quarkus.component.knative.consumer.it;
+
+import java.util.UUID;
+import java.util.concurrent.TimeUnit;
+
+import javax.ws.rs.core.MediaType;
+
+import io.quarkus.test.junit.QuarkusTest;
+import io.restassured.path.json.JsonPath;
+import org.apache.camel.component.cloudevents.CloudEvents;
+import org.apache.camel.component.knative.http.KnativeHttpConsumerFactory;
+import org.awaitility.Awaitility;
+import org.junit.jupiter.api.Test;
+
+import static io.restassured.RestAssured.given;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+@QuarkusTest
+public class KnativeEventConsumerTest {
+
+ @Test
+ void consumeFromBroker() {
+ given()
+ .contentType(MediaType.TEXT_PLAIN)
+ .accept(MediaType.TEXT_PLAIN)
+ .header("ce-type", "event-test")
+ .header("ce-specversion", CloudEvents.v1_0.version())
+ .header("ce-id", UUID.randomUUID())
+ .header("ce-time", "2018-04-05T17:31:00Z")
+ .header("ce-source", "camel-event-test")
+ .body("Hello World - Testing Knative Broker Camel consumer")
+ .when()
+ .post("/")
+ .then()
+ .statusCode(200);
+
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/")
+ .then()
+ .extract().body().asString();
+ return body != null && body.contains("Hello World - Testing Knative Broker Camel consumer");
+ });
+ }
+
+
+}
diff --git a/integration-tests/knative-producer/Readme.adoc b/integration-tests/knative-producer/Readme.adoc
new file mode 100644
index 0000000000..c38ab36fa8
--- /dev/null
+++ b/integration-tests/knative-producer/Readme.adoc
@@ -0,0 +1,11 @@
+= Knative Producer tests
+
+The tests able to run against Mocked Knative HTTP API.
+
+If you wish to test this application in knative environment, follow these steps :
+* Create an InMemory Knative Channel named `channel-test`
+* Create an InMemory Knative Broker named `broker-test`
+* Deploy a Knative Service named `endpoint-test`
+* Deploy this application within the Kubernetes cluster
+* Make sure the application can use secrets containing the URLs : KNATIVE_CHANNEL_URL, KNATIVE_CHANNEL_URL, KNATIVE_SERVICE_URL
+* On native mode, you may need to set `quarkus.ssl.native=true` in case one those URLs uses `https` instead of `http`
\ No newline at end of file
diff --git a/integration-tests/knative-producer/pom.xml b/integration-tests/knative-producer/pom.xml
new file mode 100644
index 0000000000..7d441d7e4a
--- /dev/null
+++ b/integration-tests/knative-producer/pom.xml
@@ -0,0 +1,176 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-build-parent-it</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../../poms/build-parent-it/pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-integration-test-knative-producer</artifactId>
+ <name>Camel Quarkus :: Integration Tests :: Knative Producer</name>
+ <description>Integration tests for Camel Quarkus Knative Producer extension</description>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer</artifactId>
+ </dependency>
+
+ <!-- camel quarkus -->
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-resteasy-jsonb</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-mock</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-direct</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-timer</artifactId>
+ </dependency>
+
+ <!-- test dependencies -->
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-junit5</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>io.rest-assured</groupId>
+ <artifactId>rest-assured</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.awaitility</groupId>
+ <artifactId>awaitility</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <!-- dependencies needed to mock Knative HTTP -->
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-integration-wiremock-support</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <profiles>
+ <profile>
+ <id>native</id>
+ <activation>
+ <property>
+ <name>native</name>
+ </property>
+ </activation>
+ <properties>
+ <quarkus.package.type>native</quarkus.package.type>
+ </properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-failsafe-plugin</artifactId>
+ <executions>
+ <execution>
+ <goals>
+ <goal>integration-test</goal>
+ <goal>verify</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>virtualDependencies</id>
+ <activation>
+ <property>
+ <name>!noVirtualDependencies</name>
+ </property>
+ </activation>
+ <dependencies>
+ <!-- The following dependencies guarantee that this module is built after them. You can update them by running `mvn process-resources -Pformat -N` from the source tree root directory -->
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-direct-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-mock-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-timer-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ </dependencies>
+ </profile>
+ </profiles>
+
+</project>
\ No newline at end of file
diff --git a/integration-tests/knative-producer/src/main/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerResource.java b/integration-tests/knative-producer/src/main/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerResource.java
new file mode 100644
index 0000000000..72eac89286
--- /dev/null
+++ b/integration-tests/knative-producer/src/main/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerResource.java
@@ -0,0 +1,124 @@
+/*
+ * 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.quarkus.component.knative.producer.it;
+
+import java.time.format.DateTimeFormatter;
+import java.time.format.DateTimeParseException;
+
+import javax.enterprise.context.ApplicationScoped;
+import javax.inject.Inject;
+import javax.json.Json;
+import javax.json.JsonObject;
+import javax.ws.rs.Consumes;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.PathParam;
+import javax.ws.rs.Produces;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+
+import org.apache.camel.CamelContext;
+import org.apache.camel.Exchange;
+import org.apache.camel.ProducerTemplate;
+import org.apache.camel.component.cloudevents.CloudEvents;
+import org.apache.camel.component.knative.KnativeComponent;
+import org.apache.camel.component.mock.MockEndpoint;
+
+@Path("/knative-producer")
+@ApplicationScoped
+public class KnativeProducerResource {
+ @Inject
+ CamelContext context;
+
+ @Inject
+ ProducerTemplate producerTemplate;
+
+ @GET
+ @Path("inspect")
+ @Produces(MediaType.APPLICATION_JSON)
+ public JsonObject inspect() {
+ var component = context.getComponent("knative", KnativeComponent.class);
+ var builder = Json.createObjectBuilder();
+
+ if (component.getProducerFactory() != null) {
+ builder.add("producer-factory", component.getProducerFactory().getClass().getName());
+ }
+ if (component.getConsumerFactory() != null) {
+ builder.add("consumer-factory", component.getConsumerFactory().getClass().getName());
+ }
+
+ return builder.build();
+ }
+
+ @GET
+ @Path("/send/{type}/{msg}")
+ public Response sendMessageToChannel(@PathParam("type") String type, @PathParam("msg") String message) {
+ producerTemplate.sendBody(String.format("direct:%s", type), message);
+ return Response.ok().build();
+ }
+
+ @Path("/mock/{name}")
+ @GET
+ @Consumes(MediaType.TEXT_PLAIN)
+ @Produces(MediaType.TEXT_PLAIN)
+ public boolean validProducedCloudEvent(@PathParam("name") String endpointName) {
+ MockEndpoint mockEndpoint = context.getEndpoint(String.format("mock:%s", endpointName), MockEndpoint.class);
+ Exchange result = mockEndpoint.getReceivedExchanges().stream()
+ .findAny().get();
+
+ // check there is a time
+ String time = result.getMessage().getHeader("ce-time", String.class);
+ if (time == null) {
+ return false;
+ }
+ // check the time is valid
+ try {
+ DateTimeFormatter.ISO_INSTANT.parse(time);
+ } catch (DateTimeParseException e) {
+ // if no valid time format return false
+ return false;
+ }
+ // check there is an id
+ String id = result.getMessage().getHeader("ce-id", String.class);
+ if (id == null) {
+ return false;
+ }
+ // check there is a source
+ String source = result.getMessage().getHeader("ce-source", String.class);
+ if (source == null) {
+ return false;
+ }
+ // check there is a type
+ String type = result.getMessage().getHeader("ce-type", String.class);
+ if (type == null) {
+ return false;
+ }
+ // check there is a spec version
+ String specVersion = result.getMessage().getHeader("ce-specversion", String.class);
+ if (specVersion == null) {
+ return false;
+ }
+ // check spec version is valid
+ if (CloudEvents.v1_0.version().equals(specVersion) || CloudEvents.v1_0_1.version().equals(specVersion)) {
+ return true;
+ }
+
+ // spec version invalid
+ return false;
+
+ }
+}
diff --git a/integration-tests/knative-producer/src/main/java/org/apache/camel/quarkus/component/knative/producer/it/Routes.java b/integration-tests/knative-producer/src/main/java/org/apache/camel/quarkus/component/knative/producer/it/Routes.java
new file mode 100644
index 0000000000..529b26f1c0
--- /dev/null
+++ b/integration-tests/knative-producer/src/main/java/org/apache/camel/quarkus/component/knative/producer/it/Routes.java
@@ -0,0 +1,72 @@
+/*
+ * 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.quarkus.component.knative.producer.it;
+
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.cloudevents.CloudEvent;
+
+public class Routes extends RouteBuilder {
+
+ private static final String TIME = "2018-04-05T17:31:00Z";
+
+ @Override
+ public void configure() throws Exception {
+ // Routes using ProducerTemplate, need to specify the header CloudEvent.CAMEL_CLOUD_EVENT_SOURCE
+ from("direct:channel")
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_SOURCE, constant("camel"))
+ // temporary fix until the issue is available https://issues.apache.org/jira/browse/CAMEL-18473 on camel-quarkus
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_TIME, constant(TIME))
+ .to("knative:channel/channel-test")
+ .to("mock:channel");
+
+ from("direct:event")
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_SOURCE, constant("camel"))
+ // temporary fix until the issue is available https://issues.apache.org/jira/browse/CAMEL-18473 on camel-quarkus
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_TIME, constant(TIME))
+ .to("knative:event/broker-test")
+ .to("mock:event");
+
+ from("direct:endpoint")
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_SOURCE, constant("camel"))
+ // temporary fix until the issue is available https://issues.apache.org/jira/browse/CAMEL-18473 on camel-quarkus
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_TIME, constant(TIME))
+ .to("knative:endpoint/endpoint-test")
+ .to("mock:endpoint");
+
+ // Routes not using ProducerTemplate, the cloud event source header is managed by the consumer
+ from("timer:channelTimer?period=1")
+ .setBody(constant("Hello World From channelTimer!"))
+ // temporary fix until the issue is available https://issues.apache.org/jira/browse/CAMEL-18473 on camel-quarkus
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_TIME, constant(TIME))
+ .to("knative:channel/channel-test")
+ .to("mock:channel-timer");
+
+ from("timer:eventTimer?period=1")
+ .setBody(constant("Hello World From eventTimer!"))
+ // temporary fix until the issue is available https://issues.apache.org/jira/browse/CAMEL-18473 on camel-quarkus
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_TIME, constant(TIME))
+ .to("knative:event/broker-test")
+ .to("mock:event-timer");
+
+ from("timer:endpointTimer?period=1")
+ .setBody(constant("Hello World From endpointTimer!"))
+ // temporary fix until the issue is available https://issues.apache.org/jira/browse/CAMEL-18473 on camel-quarkus
+ .setHeader(CloudEvent.CAMEL_CLOUD_EVENT_TIME, constant(TIME))
+ .to("knative:endpoint/endpoint-test")
+ .to("mock:endpoint-timer");
+ }
+}
diff --git a/integration-tests/knative-producer/src/main/resources/application.properties b/integration-tests/knative-producer/src/main/resources/application.properties
new file mode 100644
index 0000000000..f1ac9d3f42
--- /dev/null
+++ b/integration-tests/knative-producer/src/main/resources/application.properties
@@ -0,0 +1,40 @@
+## ---------------------------------------------------------------------------
+## 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.
+## ---------------------------------------------------------------------------
+
+
+channel.test.url = TODO
+broker.test.url = TODO
+service.test.url = TODO
+
+# channel configuration
+camel.component.knative.environment.resources[0].name = channel-test
+camel.component.knative.environment.resources[0].type = channel
+camel.component.knative.environment.resources[0].endpoint-kind = sink
+camel.component.knative.environment.resources[0].url = ${KNATIVE_CHANNEL_URL:{{channel.test.url}}}
+
+# broker configuration
+camel.component.knative.environment.resources[1].name = broker-test
+camel.component.knative.environment.resources[1].type = event
+camel.component.knative.environment.resources[1].endpoint-kind = sink
+camel.component.knative.environment.resources[1].url = ${KNATIVE_CHANNEL_URL:{{broker.test.url}}}
+camel.component.knative.environment.resources[1].cloudEventType = org.apache.camel.event
+
+# endpoint configuration
+camel.component.knative.environment.resources[2].name = endpoint-test
+camel.component.knative.environment.resources[2].type = endpoint
+camel.component.knative.environment.resources[2].endpoint-kind = sink
+camel.component.knative.environment.resources[2].url = ${KNATIVE_SERVICE_URL:{{service.test.url}}}
\ No newline at end of file
diff --git a/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerIT.java b/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerIT.java
new file mode 100644
index 0000000000..33d11ec80e
--- /dev/null
+++ b/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerIT.java
@@ -0,0 +1,23 @@
+/*
+ * 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.quarkus.component.knative.producer.it;
+
+import io.quarkus.test.junit.QuarkusIntegrationTest;
+
+@QuarkusIntegrationTest
+public class KnativeProducerIT extends KnativeProducerTest {
+}
diff --git a/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerTest.java b/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerTest.java
new file mode 100644
index 0000000000..dc8b1f7c6c
--- /dev/null
+++ b/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeProducerTest.java
@@ -0,0 +1,134 @@
+/*
+ * 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.quarkus.component.knative.producer.it;
+
+import java.util.concurrent.TimeUnit;
+
+import javax.ws.rs.core.MediaType;
+
+import io.quarkus.test.common.QuarkusTestResource;
+import io.quarkus.test.common.http.TestHTTPEndpoint;
+import io.quarkus.test.junit.QuarkusTest;
+import io.restassured.path.json.JsonPath;
+import org.apache.camel.component.knative.http.KnativeHttpProducerFactory;
+import org.awaitility.Awaitility;
+import org.junit.jupiter.api.Test;
+
+import static io.restassured.RestAssured.given;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+@QuarkusTest
+@TestHTTPEndpoint(KnativeProducerResource.class)
+@QuarkusTestResource(KnativeTestResource.class)
+public class KnativeProducerTest {
+ @Test
+ void inspect() {
+ JsonPath p = given()
+ .contentType(MediaType.TEXT_PLAIN)
+ .accept(MediaType.APPLICATION_JSON)
+ .get("/inspect")
+ .then()
+ .statusCode(200)
+ .extract()
+ .body()
+ .jsonPath();
+
+ assertEquals(KnativeHttpProducerFactory.class.getName(), p.getString("producer-factory"));
+ }
+
+ @Test
+ void sendToChannelWithProducerTemplate() {
+ given()
+ .get("/send/channel/HelloWorld")
+ .then()
+ .statusCode(200);
+
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/mock/channel")
+ .then()
+ .extract().body().asString();
+ return body != null && "true".equals(body);
+ });
+ }
+
+ @Test
+ void sendToBrokerWithProducerTemplate() {
+ given()
+ .get("/send/event/HelloWorld")
+ .then()
+ .statusCode(200);
+
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/mock/event")
+ .then()
+ .extract().body().asString();
+ return body != null && "true".equals(body);
+ });
+ }
+
+ @Test
+ void sendToEndpointWithProducerTemplate() {
+ given()
+ .get("/send/endpoint/HelloWorld")
+ .then()
+ .statusCode(200);
+
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/mock/endpoint")
+ .then()
+ .extract().body().asString();
+ return body != null && "true".equals(body);
+ });
+ }
+
+ @Test
+ void sendToChannelWithTimer() {
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/mock/channel-timer")
+ .then()
+ .extract().body().asString();
+ return body != null && "true".equals(body);
+ });
+ }
+
+ @Test
+ void sendToBrokerWithTimer() {
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/mock/event-timer")
+ .then()
+ .extract().body().asString();
+ return body != null && "true".equals(body);
+ });
+ }
+
+ @Test
+ void sendToServiceWithTimer() {
+ Awaitility.await().pollInterval(1, TimeUnit.SECONDS).atMost(10, TimeUnit.SECONDS).until(() -> {
+ final String body = given()
+ .get("/mock/endpoint-timer")
+ .then()
+ .extract().body().asString();
+ return body != null && "true".equals(body);
+ });
+ }
+
+}
diff --git a/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeTestResource.java b/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeTestResource.java
new file mode 100644
index 0000000000..19c4328a6e
--- /dev/null
+++ b/integration-tests/knative-producer/src/test/java/org/apache/camel/quarkus/component/knative/producer/it/KnativeTestResource.java
@@ -0,0 +1,50 @@
+/*
+ * 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.quarkus.component.knative.producer.it;
+
+import java.util.Map;
+
+import org.apache.camel.quarkus.test.wiremock.WireMockTestResourceLifecycleManager;
+
+public class KnativeTestResource extends WireMockTestResourceLifecycleManager {
+
+ private static final String KNATIVE_CHANNEL_URL = "KNATIVE_CHANNEL_URL";
+ private static final String KNATIVE_BROKER_URL = "KNATIVE_BROKER_URL";
+ private static final String KNATIVE_SERVICE_URL = "KNATIVE_SERVICE_URL";
+
+ @Override
+ protected String getRecordTargetBaseUrl() {
+ return "/";
+ }
+
+ @Override
+ protected boolean isMockingEnabled() {
+ return !envVarsPresent(KNATIVE_CHANNEL_URL, KNATIVE_BROKER_URL, KNATIVE_SERVICE_URL);
+ }
+
+ @Override
+ public Map<String, String> start() {
+ Map<String, String> options = super.start();
+ if (options.containsKey("wiremock.url")) {
+ String wiremockUrl = options.get("wiremock.url");
+ options.put("channel.test.url", String.format("%s/channel-test", wiremockUrl));
+ options.put("broker.test.url", String.format("%s/broker-test", wiremockUrl));
+ options.put("service.test.url", String.format("%s/service-test", wiremockUrl));
+ }
+ return options;
+ }
+}
diff --git a/integration-tests/knative-producer/src/test/resources/mappings/sendToBroker.json b/integration-tests/knative-producer/src/test/resources/mappings/sendToBroker.json
new file mode 100644
index 0000000000..38294518ca
--- /dev/null
+++ b/integration-tests/knative-producer/src/test/resources/mappings/sendToBroker.json
@@ -0,0 +1,17 @@
+{
+ "id": "09aa79df-8a19-41df-8655-e414d390d6ed",
+ "name": "knative-http_api",
+ "request": {
+ "url": "/broker-test",
+ "method": "POST"
+ },
+ "response": {
+ "status": 202,
+ "headers": {
+ "Content-Type": "application/json; charset=UTF-8"
+ }
+ },
+ "uuid": "09aa79df-8a19-41df-8655-e414d390d6ed",
+ "persistent": true,
+ "insertionIndex": 2
+}
\ No newline at end of file
diff --git a/integration-tests/knative-producer/src/test/resources/mappings/sendToChannel.json b/integration-tests/knative-producer/src/test/resources/mappings/sendToChannel.json
new file mode 100644
index 0000000000..454b746e14
--- /dev/null
+++ b/integration-tests/knative-producer/src/test/resources/mappings/sendToChannel.json
@@ -0,0 +1,17 @@
+{
+ "id": "09aa79df-8a19-41df-8655-e414d390d6ed",
+ "name": "knative-http_api",
+ "request": {
+ "url": "/channel-test",
+ "method": "POST"
+ },
+ "response": {
+ "status": 202,
+ "headers": {
+ "Content-Type": "application/json; charset=UTF-8"
+ }
+ },
+ "uuid": "09aa79df-8a19-41df-8655-e414d390d6ed",
+ "persistent": true,
+ "insertionIndex": 2
+}
\ No newline at end of file
diff --git a/integration-tests/knative-producer/src/test/resources/mappings/sendToService.json b/integration-tests/knative-producer/src/test/resources/mappings/sendToService.json
new file mode 100644
index 0000000000..b683cd5402
--- /dev/null
+++ b/integration-tests/knative-producer/src/test/resources/mappings/sendToService.json
@@ -0,0 +1,17 @@
+{
+ "id": "09aa79df-8a19-41df-8655-e414d390d6ed",
+ "name": "knative-http_api",
+ "request": {
+ "url": "/service-test",
+ "method": "POST"
+ },
+ "response": {
+ "status": 202,
+ "headers": {
+ "Content-Type": "application/json; charset=UTF-8"
+ }
+ },
+ "uuid": "09aa79df-8a19-41df-8655-e414d390d6ed",
+ "persistent": true,
+ "insertionIndex": 2
+}
\ No newline at end of file
diff --git a/integration-tests/knative/pom.xml b/integration-tests/knative/pom.xml
new file mode 100644
index 0000000000..f0884b7b2a
--- /dev/null
+++ b/integration-tests/knative/pom.xml
@@ -0,0 +1,114 @@
+<?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.quarkus</groupId>
+ <artifactId>camel-quarkus-build-parent-it</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ <relativePath>../../poms/build-parent-it/pom.xml</relativePath>
+ </parent>
+
+ <artifactId>camel-quarkus-integration-test-knative</artifactId>
+ <name>Camel Quarkus :: Integration Tests :: Knative</name>
+ <description>Integration tests for Camel Quarkus Knative extension</description>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-resteasy-jsonb</artifactId>
+ </dependency>
+
+ <!-- test dependencies -->
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-junit5</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>io.rest-assured</groupId>
+ <artifactId>rest-assured</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <profiles>
+ <profile>
+ <id>native</id>
+ <activation>
+ <property>
+ <name>native</name>
+ </property>
+ </activation>
+ <properties>
+ <quarkus.package.type>native</quarkus.package.type>
+ </properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-failsafe-plugin</artifactId>
+ <executions>
+ <execution>
+ <goals>
+ <goal>integration-test</goal>
+ <goal>verify</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>virtualDependencies</id>
+ <activation>
+ <property>
+ <name>!noVirtualDependencies</name>
+ </property>
+ </activation>
+ <dependencies>
+ <!-- The following dependencies guarantee that this module is built after them. You can update them by running `mvn process-resources -Pformat -N` from the source tree root directory -->
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>*</groupId>
+ <artifactId>*</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+
+ </dependencies>
+ </profile>
+
+ </profiles>
+
+</project>
diff --git a/integration-tests/knative/src/main/java/org/apache/camel/quarkus/component/knative/it/KnativeResource.java b/integration-tests/knative/src/main/java/org/apache/camel/quarkus/component/knative/it/KnativeResource.java
new file mode 100644
index 0000000000..6db339995c
--- /dev/null
+++ b/integration-tests/knative/src/main/java/org/apache/camel/quarkus/component/knative/it/KnativeResource.java
@@ -0,0 +1,49 @@
+/*
+ * 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.quarkus.component.knative.it;
+
+import javax.enterprise.context.ApplicationScoped;
+import javax.inject.Inject;
+import javax.json.Json;
+import javax.json.JsonObject;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.Produces;
+import javax.ws.rs.core.MediaType;
+
+import org.apache.camel.CamelContext;
+import org.apache.camel.component.knative.KnativeComponent;
+
+@Path("/knative")
+@ApplicationScoped
+public class KnativeResource {
+
+ @Inject
+ CamelContext context;
+
+ @GET
+ @Path("/inspect")
+ @Produces(MediaType.APPLICATION_JSON)
+ public JsonObject inspect() {
+ return Json.createObjectBuilder()
+ .add("producer-factory",
+ context.getComponent("knative", KnativeComponent.class).getProducerFactory().getClass().getName())
+ .add("consumer-factory",
+ context.getComponent("knative", KnativeComponent.class).getConsumerFactory().getClass().getName())
+ .build();
+ }
+}
diff --git a/integration-tests/knative/src/test/java/org/apache/camel/quarkus/component/knative/it/KnativeIT.java b/integration-tests/knative/src/test/java/org/apache/camel/quarkus/component/knative/it/KnativeIT.java
new file mode 100644
index 0000000000..ec51d807e4
--- /dev/null
+++ b/integration-tests/knative/src/test/java/org/apache/camel/quarkus/component/knative/it/KnativeIT.java
@@ -0,0 +1,24 @@
+/*
+ * 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.quarkus.component.knative.it;
+
+import io.quarkus.test.junit.QuarkusIntegrationTest;
+
+@QuarkusIntegrationTest
+class KnativeIT extends KnativeTest {
+
+}
diff --git a/integration-tests/knative/src/test/java/org/apache/camel/quarkus/component/knative/it/KnativeTest.java b/integration-tests/knative/src/test/java/org/apache/camel/quarkus/component/knative/it/KnativeTest.java
new file mode 100644
index 0000000000..1867bf2b6d
--- /dev/null
+++ b/integration-tests/knative/src/test/java/org/apache/camel/quarkus/component/knative/it/KnativeTest.java
@@ -0,0 +1,50 @@
+/*
+ * 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.quarkus.component.knative.it;
+
+import javax.ws.rs.core.MediaType;
+
+import io.quarkus.test.common.http.TestHTTPEndpoint;
+import io.quarkus.test.junit.QuarkusTest;
+import io.restassured.RestAssured;
+import io.restassured.path.json.JsonPath;
+import org.apache.camel.component.knative.http.KnativeHttpConsumerFactory;
+import org.apache.camel.component.knative.http.KnativeHttpProducerFactory;
+import org.junit.jupiter.api.Test;
+
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+@QuarkusTest
+@TestHTTPEndpoint(KnativeResource.class)
+class KnativeTest {
+
+ @Test
+ public void inspect() {
+ JsonPath p = RestAssured.given()
+ .accept(MediaType.APPLICATION_JSON)
+ .get("/inspect")
+ .then()
+ .statusCode(200)
+ .extract()
+ .body()
+ .jsonPath();
+
+ assertEquals(KnativeHttpConsumerFactory.class.getName(), p.getString("consumer-factory"));
+ assertEquals(KnativeHttpProducerFactory.class.getName(), p.getString("producer-factory"));
+ }
+
+}
diff --git a/integration-tests/pom.xml b/integration-tests/pom.xml
index 446b91c679..e2a1e23bef 100644
--- a/integration-tests/pom.xml
+++ b/integration-tests/pom.xml
@@ -136,6 +136,11 @@
<module>kafka-sasl-ssl</module>
<module>kafka-ssl</module>
<module>kamelet</module>
+ <module>knative</module>
+ <module>knative-channel-consumer</module>
+ <module>knative-endpoint-consumer</module>
+ <module>knative-event-consumer</module>
+ <module>knative-producer</module>
<module>kotlin</module>
<module>kubernetes</module>
<module>kudu</module>
diff --git a/poms/bom/pom.xml b/poms/bom/pom.xml
index 29e8d5d2cc..ab4283b8fa 100644
--- a/poms/bom/pom.xml
+++ b/poms/bom/pom.xml
@@ -1300,6 +1300,11 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-cloudevents</artifactId>
+ <version>${camel.version}</version>
+ </dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-cluster</artifactId>
@@ -3769,6 +3774,21 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-knative</artifactId>
+ <version>${camel.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-knative-api</artifactId>
+ <version>${camel.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-knative-http</artifactId>
+ <version>${camel.version}</version>
+ </dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-kotlin-dsl</artifactId>
@@ -6636,6 +6656,16 @@
<artifactId>camel-quarkus-chunk-deployment</artifactId>
<version>${camel-quarkus.version}</version>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents</artifactId>
+ <version>${camel-quarkus.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents-deployment</artifactId>
+ <version>${camel-quarkus.version}</version>
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-cm-sms</artifactId>
@@ -7811,6 +7841,36 @@
<artifactId>camel-quarkus-kamelet-deployment</artifactId>
<version>${camel-quarkus.version}</version>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative</artifactId>
+ <version>${camel-quarkus.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+ <version>${camel-quarkus.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer-deployment</artifactId>
+ <version>${camel-quarkus.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-deployment</artifactId>
+ <version>${camel-quarkus.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer</artifactId>
+ <version>${camel-quarkus.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer-deployment</artifactId>
+ <version>${camel-quarkus.version}</version>
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-kotlin</artifactId>
diff --git a/poms/bom/src/main/generated/flattened-full-pom.xml b/poms/bom/src/main/generated/flattened-full-pom.xml
index 518cf1da94..c895e1c9b6 100644
--- a/poms/bom/src/main/generated/flattened-full-pom.xml
+++ b/poms/bom/src/main/generated/flattened-full-pom.xml
@@ -1239,6 +1239,11 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-cloudevents</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>3.18.2</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
<dependency>
<groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<artifactId>camel-cluster</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
@@ -3708,6 +3713,21 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-knative</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>3.18.2</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-knative-api</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>3.18.2</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-knative-http</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>3.18.2</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
<dependency>
<groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<artifactId>camel-kotlin-dsl</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
@@ -6573,6 +6593,16 @@
<artifactId>camel-quarkus-chunk-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-cloudevents</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-cloudevents-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<artifactId>camel-quarkus-cm-sms</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
@@ -7748,6 +7778,36 @@
<artifactId>camel-quarkus-kamelet-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-consumer</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-consumer-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-producer</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-producer-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<artifactId>camel-quarkus-kotlin</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
diff --git a/poms/bom/src/main/generated/flattened-reduced-pom.xml b/poms/bom/src/main/generated/flattened-reduced-pom.xml
index 46c3b1d20c..5b0882df08 100644
--- a/poms/bom/src/main/generated/flattened-reduced-pom.xml
+++ b/poms/bom/src/main/generated/flattened-reduced-pom.xml
@@ -1239,6 +1239,11 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-cloudevents</artifactId>
+ <version>3.18.2</version>
+ </dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-cluster</artifactId>
@@ -3708,6 +3713,21 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-knative</artifactId>
+ <version>3.18.2</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-knative-api</artifactId>
+ <version>3.18.2</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-knative-http</artifactId>
+ <version>3.18.2</version>
+ </dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-kotlin-dsl</artifactId>
@@ -6573,6 +6593,16 @@
<artifactId>camel-quarkus-chunk-deployment</artifactId>
<version>2.14.0-SNAPSHOT</version>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-cloudevents-deployment</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-cm-sms</artifactId>
@@ -7748,6 +7778,36 @@
<artifactId>camel-quarkus-kamelet-deployment</artifactId>
<version>2.14.0-SNAPSHOT</version>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-consumer-deployment</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-deployment</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId>
+ <artifactId>camel-quarkus-knative-producer-deployment</artifactId>
+ <version>2.14.0-SNAPSHOT</version>
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId>
<artifactId>camel-quarkus-kotlin</artifactId>
diff --git a/poms/bom/src/main/generated/flattened-reduced-verbose-pom.xml b/poms/bom/src/main/generated/flattened-reduced-verbose-pom.xml
index eaea6b86d8..18f9328e0e 100644
--- a/poms/bom/src/main/generated/flattened-reduced-verbose-pom.xml
+++ b/poms/bom/src/main/generated/flattened-reduced-verbose-pom.xml
@@ -1239,6 +1239,11 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-cloudevents</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>3.18.2</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
<dependency>
<groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<artifactId>camel-cluster</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
@@ -3708,6 +3713,21 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-knative</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>3.18.2</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-knative-api</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>3.18.2</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-knative-http</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>3.18.2</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
<dependency>
<groupId>org.apache.camel</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<artifactId>camel-kotlin-dsl</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
@@ -6573,6 +6593,16 @@
<artifactId>camel-quarkus-chunk-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-cloudevents</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-cloudevents-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<artifactId>camel-quarkus-cm-sms</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
@@ -7748,6 +7778,36 @@
<artifactId>camel-quarkus-kamelet-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
</dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-consumer</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-consumer-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-producer</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <artifactId>camel-quarkus-knative-producer-deployment</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ <version>2.14.0-SNAPSHOT</version><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
+ </dependency>
<dependency>
<groupId>org.apache.camel.quarkus</groupId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
<artifactId>camel-quarkus-kotlin</artifactId><!-- org.apache.camel.quarkus:camel-quarkus-bom:${project.version} -->
diff --git a/tooling/scripts/test-categories.yaml b/tooling/scripts/test-categories.yaml
index b1b5e9f660..786930f5d4 100644
--- a/tooling/scripts/test-categories.yaml
+++ b/tooling/scripts/test-categories.yaml
@@ -182,6 +182,11 @@ group-12:
- aws2-grouped
- csimple
- quartz-clustered
+ - knative
+ - knative-channel-consumer
+ - knative-endpoint-consumer
+ - knative-event-consumer
+ - knative-producer
- microprofile
- openapi-java
- opentracing