You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ja...@apache.org on 2023/10/31 15:43:35 UTC

(camel-quarkus) branch main updated (49118198b6 -> 4baef5ceeb)

This is an automated email from the ASF dual-hosted git repository.

jamesnetherton pushed a change to branch main
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git


    from 49118198b6 Automatically register beans with methods annotated with @Handler for reflection
     new a008b494c0 Add missing transformer service pattern include
     new 376f1a11eb Add capability to log potentially missing service pattern includes
     new 4baef5ceeb Add basic test coverage for transformer EIP

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../quarkus/core/deployment/CamelProcessor.java    | 51 +++++++++++++++++++++-
 extensions/aws2-s3/deployment/pom.xml              |  4 ++
 extensions/aws2-s3/runtime/pom.xml                 |  4 ++
 integration-test-groups/foundation/pom.xml         |  1 +
 .../foundation/{log => transformer}/pom.xml        |  9 +---
 .../camel/quarkus/transformer/TransformerBean.java | 17 +++++---
 .../transformer/TransformerBeanConverter.java}     | 16 ++++---
 .../quarkus/transformer/TransformerResource.java}  | 46 ++++++++++---------
 .../quarkus/transformer/TransformerRoutes.java     | 17 +++++---
 .../camel/quarkus/transformer/TransformerIT.java}  |  5 +--
 .../camel/quarkus/transformer/TransformerTest.java | 30 +++++++------
 11 files changed, 140 insertions(+), 60 deletions(-)
 copy integration-test-groups/foundation/{log => transformer}/pom.xml (94%)
 copy integration-tests/camel-k-runtime/src/main/java/org/apache/camel/quarkus/k/it/yaml/MyProcessor.java => integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerBean.java (73%)
 copy integration-test-groups/foundation/{type-converter/src/main/java/org/apache/camel/quarkus/core/converter/it/SimpleBeanConverter.java => transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerBeanConverter.java} (68%)
 copy integration-test-groups/foundation/{bean/src/main/java/org/apache/camel/quarkus/component/bean/eip/EipResource.java => transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerResource.java} (57%)
 copy integration-tests/base64/src/main/java/org/apache/camel/quarkus/component/base64/it/Base64RouteBuilder.java => integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerRoutes.java (62%)
 copy integration-test-groups/{aws2/aws2-s3/src/test/java/org/apache/camel/quarkus/component/aws2/s3/it/Aws2S3IT.java => foundation/transformer/src/test/java/org/apache/camel/quarkus/transformer/TransformerIT.java} (89%)
 copy integration-tests/qute/src/test/java/org/apache/camel/quarkus/component/qute/it/QuteTest.java => integration-test-groups/foundation/transformer/src/test/java/org/apache/camel/quarkus/transformer/TransformerTest.java (60%)


(camel-quarkus) 03/03: Add basic test coverage for transformer EIP

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jamesnetherton pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git

commit 4baef5ceeb0880eb01c0289f29829a183c981030
Author: James Netherton <ja...@gmail.com>
AuthorDate: Tue Oct 31 09:42:07 2023 +0000

    Add basic test coverage for transformer EIP
---
 integration-test-groups/foundation/pom.xml         |   1 +
 .../foundation/transformer/pom.xml                 | 126 +++++++++++++++++++++
 .../camel/quarkus/transformer/TransformerBean.java |  33 ++++++
 .../transformer/TransformerBeanConverter.java      |  34 ++++++
 .../quarkus/transformer/TransformerResource.java   |  65 +++++++++++
 .../quarkus/transformer/TransformerRoutes.java     |  36 ++++++
 .../camel/quarkus/transformer/TransformerIT.java   |  23 ++++
 .../camel/quarkus/transformer/TransformerTest.java |  54 +++++++++
 8 files changed, 372 insertions(+)

diff --git a/integration-test-groups/foundation/pom.xml b/integration-test-groups/foundation/pom.xml
index 66b31115b8..b76122511b 100644
--- a/integration-test-groups/foundation/pom.xml
+++ b/integration-test-groups/foundation/pom.xml
@@ -55,6 +55,7 @@
         <module>seda</module>
         <module>stream</module>
         <module>timer</module>
+        <module>transformer</module>
         <module>type-converter</module>
     </modules>
 
diff --git a/integration-test-groups/foundation/transformer/pom.xml b/integration-test-groups/foundation/transformer/pom.xml
new file mode 100644
index 0000000000..e7a40c1059
--- /dev/null
+++ b/integration-test-groups/foundation/transformer/pom.xml
@@ -0,0 +1,126 @@
+<?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>3.6.0-SNAPSHOT</version>
+        <relativePath>../../../poms/build-parent-it/pom.xml</relativePath>
+    </parent>
+
+    <artifactId>camel-quarkus-integration-test-transformer</artifactId>
+    <name>Camel Quarkus :: Integration Tests :: Transformer :: Tests</name>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-direct</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-log</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>
+    </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-log-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-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerBean.java b/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerBean.java
new file mode 100644
index 0000000000..9d59132b47
--- /dev/null
+++ b/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerBean.java
@@ -0,0 +1,33 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.quarkus.transformer;
+
+import io.quarkus.runtime.annotations.RegisterForReflection;
+
+@RegisterForReflection(fields = false, methods = false)
+public class TransformerBean {
+    private final String message;
+
+    public TransformerBean(String message) {
+        this.message = message;
+    }
+
+    @Override
+    public String toString() {
+        return "Transformed " + message;
+    }
+}
diff --git a/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerBeanConverter.java b/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerBeanConverter.java
new file mode 100644
index 0000000000..c302febbc1
--- /dev/null
+++ b/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerBeanConverter.java
@@ -0,0 +1,34 @@
+/*
+ * 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.transformer;
+
+import java.nio.charset.StandardCharsets;
+
+import jakarta.inject.Singleton;
+import org.apache.camel.Converter;
+
+/**
+ * Custom TypeConverter for use with the application-octet-stream transformer
+ */
+@Singleton
+@Converter
+public class TransformerBeanConverter {
+    @Converter
+    public byte[] convertTransformerBeanToBytes(TransformerBean bean) {
+        return bean.toString().getBytes(StandardCharsets.UTF_8);
+    }
+}
diff --git a/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerResource.java b/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerResource.java
new file mode 100644
index 0000000000..b0042d1b4d
--- /dev/null
+++ b/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerResource.java
@@ -0,0 +1,65 @@
+/*
+ * 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.transformer;
+
+import jakarta.enterprise.context.ApplicationScoped;
+import jakarta.inject.Inject;
+import jakarta.ws.rs.GET;
+import jakarta.ws.rs.POST;
+import jakarta.ws.rs.Path;
+import jakarta.ws.rs.Produces;
+import jakarta.ws.rs.core.MediaType;
+import org.apache.camel.CamelContext;
+import org.apache.camel.ProducerTemplate;
+import org.apache.camel.spi.TransformerRegistry;
+
+@Path("/transformer")
+@ApplicationScoped
+public class TransformerResource {
+    @Inject
+    CamelContext context;
+
+    @Inject
+    ProducerTemplate producerTemplate;
+
+    @Path("/registry")
+    @GET
+    @Produces(MediaType.TEXT_PLAIN)
+    public String transformerRegistry() {
+        TransformerRegistry transformerRegistry = context.getTransformerRegistry();
+        if (transformerRegistry != null) {
+            return transformerRegistry.getClass().getName();
+        }
+        return null;
+    }
+
+    @Path("/toString")
+    @POST
+    @Produces(MediaType.TEXT_PLAIN)
+    public String transformBeanToString(String message) {
+        TransformerBean bean = new TransformerBean(message);
+        return (String) producerTemplate.requestBody("direct:transformBeanToString", bean);
+    }
+
+    @Path("/toBytes")
+    @POST
+    @Produces(MediaType.APPLICATION_OCTET_STREAM)
+    public byte[] transformBeanToBytes(String message) {
+        TransformerBean bean = new TransformerBean(message);
+        return (byte[]) producerTemplate.requestBody("direct:transformBeanToBytes", bean);
+    }
+}
diff --git a/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerRoutes.java b/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerRoutes.java
new file mode 100644
index 0000000000..2dedac8df7
--- /dev/null
+++ b/integration-test-groups/foundation/transformer/src/main/java/org/apache/camel/quarkus/transformer/TransformerRoutes.java
@@ -0,0 +1,36 @@
+/*
+ * 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.transformer;
+
+import org.apache.camel.builder.RouteBuilder;
+
+public class TransformerRoutes extends RouteBuilder {
+    @Override
+    public void configure() throws Exception {
+        transformer().withDefaults();
+
+        from("direct:transformBeanToString")
+                .inputType(TransformerBean.class)
+                .outputType("text-plain")
+                .log("Transformed TransformerBean to String");
+
+        from("direct:transformBeanToBytes")
+                .inputType(TransformerBean.class)
+                .outputType("application-octet-stream")
+                .log("Transformed TransformerBean to byte[]");
+    }
+}
diff --git a/integration-test-groups/foundation/transformer/src/test/java/org/apache/camel/quarkus/transformer/TransformerIT.java b/integration-test-groups/foundation/transformer/src/test/java/org/apache/camel/quarkus/transformer/TransformerIT.java
new file mode 100644
index 0000000000..e981f6c72a
--- /dev/null
+++ b/integration-test-groups/foundation/transformer/src/test/java/org/apache/camel/quarkus/transformer/TransformerIT.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.transformer;
+
+import io.quarkus.test.junit.QuarkusIntegrationTest;
+
+@QuarkusIntegrationTest
+public class TransformerIT extends TransformerTest {
+}
diff --git a/integration-test-groups/foundation/transformer/src/test/java/org/apache/camel/quarkus/transformer/TransformerTest.java b/integration-test-groups/foundation/transformer/src/test/java/org/apache/camel/quarkus/transformer/TransformerTest.java
new file mode 100644
index 0000000000..91c9f506b4
--- /dev/null
+++ b/integration-test-groups/foundation/transformer/src/test/java/org/apache/camel/quarkus/transformer/TransformerTest.java
@@ -0,0 +1,54 @@
+/*
+ * 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.transformer;
+
+import io.quarkus.test.junit.QuarkusTest;
+import io.restassured.RestAssured;
+import org.apache.camel.impl.engine.DefaultTransformerRegistry;
+import org.junit.jupiter.api.Test;
+
+import static org.hamcrest.Matchers.is;
+
+@QuarkusTest
+public class TransformerTest {
+    @Test
+    void testTransformerRegistryImpl() {
+        RestAssured.get("/transformer/registry")
+                .then()
+                .body(is(DefaultTransformerRegistry.class.getName()));
+    }
+
+    @Test
+    void testTransformBeanToString() {
+        RestAssured.given()
+                .body("To String")
+                .when()
+                .post("/transformer/toString")
+                .then()
+                .body(is("Transformed To String"));
+    }
+
+    @Test
+    void testTransformBeanToBytes() {
+        RestAssured.given()
+                .body("To Bytes")
+                .when()
+                .post("/transformer/toBytes")
+                .then()
+                .body(is("Transformed To Bytes"));
+    }
+}


(camel-quarkus) 02/03: Add capability to log potentially missing service pattern includes

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jamesnetherton pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git

commit 376f1a11eb776048c224a53e7636f480636da7c6
Author: James Netherton <ja...@gmail.com>
AuthorDate: Tue Oct 31 09:38:11 2023 +0000

    Add capability to log potentially missing service pattern includes
---
 .../quarkus/core/deployment/CamelProcessor.java    | 47 ++++++++++++++++++++++
 1 file changed, 47 insertions(+)

diff --git a/extensions-core/core/deployment/src/main/java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java b/extensions-core/core/deployment/src/main/java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java
index aa5be329f0..1a6e446233 100644
--- a/extensions-core/core/deployment/src/main/java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java
+++ b/extensions-core/core/deployment/src/main/java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java
@@ -220,6 +220,10 @@ class CamelProcessor {
                 .build();
         CamelSupport.services(applicationArchives, pathFilter)
                 .forEach(camelServices::produce);
+
+        if (LOGGER.isDebugEnabled()) {
+            debugCamelServiceInclusion(applicationArchives, servicePatterns);
+        }
     }
 
     /*
@@ -438,4 +442,47 @@ class CamelProcessor {
                 "META-INF/services/org/apache/camel/bean-processor-factory",
                 "META-INF/services/org/apache/camel/rest-registry-factory");
     }
+
+    /**
+     * Useful for identifying Camel services that are potentially not covered by inclusion patterns
+     */
+    private void debugCamelServiceInclusion(ApplicationArchivesBuildItem applicationArchives,
+            List<CamelServicePatternBuildItem> servicePatterns) {
+        PathFilter.Builder pathBuilder = new PathFilter.Builder();
+        servicePatterns.forEach(camelServicePatternBuildItem -> {
+            camelServicePatternBuildItem.getPatterns().forEach(pathBuilder::include);
+        });
+
+        PathFilter filter = pathBuilder.build();
+        HashSet<String> missingServiceIncludes = new HashSet<>();
+
+        for (ApplicationArchive archive : applicationArchives.getAllApplicationArchives()) {
+            for (Path root : archive.getRootDirectories()) {
+                final Path resourcePath = root.resolve("META-INF/services/org/apache/camel");
+
+                if (!Files.isDirectory(resourcePath)) {
+                    continue;
+                }
+
+                try (Stream<Path> files = Files.walk(resourcePath)) {
+                    files.filter(Files::isRegularFile).forEach(file -> {
+                        Path key = root.relativize(file);
+                        if (!filter.asPathPredicate().test(key)) {
+                            missingServiceIncludes.add(key.toString());
+                        }
+                    });
+                } catch (IOException e) {
+                    throw new RuntimeException(e);
+                }
+            }
+        }
+
+        if (!missingServiceIncludes.isEmpty()) {
+            // Note this is only partly reliable info as some include patterns are provided elsewhere independently of camel-quarkus-core
+            LOGGER.debug("Found potential missing service include patterns for the following paths:");
+            missingServiceIncludes.forEach(path -> {
+                LOGGER.debug("Missing service include path: {}", path);
+            });
+        }
+    }
 }


(camel-quarkus) 01/03: Add missing transformer service pattern include

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jamesnetherton pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git

commit a008b494c0890537ccbca38aa34deb71492113bc
Author: James Netherton <ja...@gmail.com>
AuthorDate: Tue Oct 31 09:37:21 2023 +0000

    Add missing transformer service pattern include
    
    Fixes #5349
---
 .../java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java | 4 +++-
 extensions/aws2-s3/deployment/pom.xml                                 | 4 ++++
 extensions/aws2-s3/runtime/pom.xml                                    | 4 ++++
 3 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/extensions-core/core/deployment/src/main/java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java b/extensions-core/core/deployment/src/main/java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java
index d9901c29a1..aa5be329f0 100644
--- a/extensions-core/core/deployment/src/main/java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java
+++ b/extensions-core/core/deployment/src/main/java/org/apache/camel/quarkus/core/deployment/CamelProcessor.java
@@ -27,6 +27,7 @@ import java.util.Set;
 import java.util.TreeSet;
 import java.util.function.Predicate;
 import java.util.stream.Collectors;
+import java.util.stream.Stream;
 
 import io.quarkus.arc.deployment.AdditionalBeanBuildItem;
 import io.quarkus.arc.deployment.BeanRegistrationPhaseBuildItem;
@@ -174,7 +175,8 @@ class CamelProcessor {
                 "META-INF/services/org/apache/camel/urifactory/*",
                 "META-INF/services/org/apache/camel/properties-function/*",
                 "META-INF/services/org/apache/camel/health-check/*",
-                "META-INF/services/org/apache/camel/periodic-task/*"));
+                "META-INF/services/org/apache/camel/periodic-task/*",
+                "META-INF/services/org/apache/camel/datatype/transformer/*"));
     }
 
     @BuildStep
diff --git a/extensions/aws2-s3/deployment/pom.xml b/extensions/aws2-s3/deployment/pom.xml
index 66efff828b..c85cc17486 100644
--- a/extensions/aws2-s3/deployment/pom.xml
+++ b/extensions/aws2-s3/deployment/pom.xml
@@ -46,6 +46,10 @@
             <groupId>org.apache.camel.quarkus</groupId>
             <artifactId>camel-quarkus-support-aws2-deployment</artifactId>
         </dependency>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-cloudevents-deployment</artifactId>
+        </dependency>
     </dependencies>
 
     <build>
diff --git a/extensions/aws2-s3/runtime/pom.xml b/extensions/aws2-s3/runtime/pom.xml
index 12148a2160..5f2dd79a54 100644
--- a/extensions/aws2-s3/runtime/pom.xml
+++ b/extensions/aws2-s3/runtime/pom.xml
@@ -50,6 +50,10 @@
             <groupId>org.apache.camel.quarkus</groupId>
             <artifactId>camel-quarkus-support-aws2</artifactId>
         </dependency>
+        <dependency>
+            <groupId>org.apache.camel.quarkus</groupId>
+            <artifactId>camel-quarkus-cloudevents</artifactId>
+        </dependency>
         <dependency>
             <groupId>io.quarkus</groupId>
             <artifactId>quarkus-jaxp</artifactId>