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

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


The following commit(s) were added to refs/heads/main by this push:
     new 102d215  CAMEL-17622: remove deprecated camel-testcontainers-junit5 
component
102d215 is described below

commit 102d2153956284dfdb0fa41d6d54b51b7cf58844
Author: Otavio Rodolfo Piske <[email protected]>
AuthorDate: Thu Feb 10 09:46:03 2022 +0100

    CAMEL-17622: remove deprecated camel-testcontainers-junit5 component
---
 .../catalog/others/testcontainers-junit5.json      |  15 ---
 .../camel-test/camel-testcontainers-junit5/pom.xml | 147 ---------------------
 .../services/org/apache/camel/other.properties     |   7 -
 .../generated/resources/testcontainers-junit5.json |  15 ---
 .../src/main/docs/testcontainers-junit5.adoc       | 142 --------------------
 .../junit5/ContainerAwareTestSupport.java          | 113 ----------------
 .../junit5/ContainerPropertiesFunction.java        |  79 -----------
 .../test/testcontainers/junit5/Containers.java     |  90 -------------
 .../camel/test/testcontainers/junit5/Wait.java     |  73 ----------
 .../junit5/ContainerAwareTestSupportIT.java        |  53 --------
 .../src/test/resources/log4j2.properties           |  30 -----
 components/camel-test/pom.xml                      |   1 -
 .../examples/json/testcontainers-junit5.json       |   1 -
 .../others/pages/testcontainers-junit5.adoc        |   1 -
 docs/user-manual/modules/ROOT/pages/testing.adoc   |   2 -
 15 files changed, 769 deletions(-)

diff --git 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/others/testcontainers-junit5.json
 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/others/testcontainers-junit5.json
deleted file mode 100644
index bb0061a..0000000
--- 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/others/testcontainers-junit5.json
+++ /dev/null
@@ -1,15 +0,0 @@
-{
-  "other": {
-    "kind": "other",
-    "name": "testcontainers-junit5",
-    "title": "Testcontainers JUnit5",
-    "description": "Camel support for testcontainers with JUnit 5",
-    "deprecated": false,
-    "firstVersion": "3.0.0",
-    "label": "testing,java,docker",
-    "supportLevel": "Stable",
-    "groupId": "org.apache.camel",
-    "artifactId": "camel-testcontainers-junit5",
-    "version": "3.16.0-SNAPSHOT"
-  }
-}
diff --git a/components/camel-test/camel-testcontainers-junit5/pom.xml 
b/components/camel-test/camel-testcontainers-junit5/pom.xml
deleted file mode 100644
index a1372b3..0000000
--- a/components/camel-test/camel-testcontainers-junit5/pom.xml
+++ /dev/null
@@ -1,147 +0,0 @@
-<?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</groupId>
-        <artifactId>camel-test-parent</artifactId>
-        <version>3.16.0-SNAPSHOT</version>
-    </parent>
-
-    <artifactId>camel-testcontainers-junit5</artifactId>
-    <packaging>jar</packaging>
-
-    <name>Camel :: Testcontainers :: JUnit 5</name>
-    <description>Camel support for testcontainers with JUnit 5</description>
-
-    <properties>
-        <firstVersion>3.0.0</firstVersion>
-        <label>testing,java,docker</label>
-        <title>Testcontainers JUnit5</title>
-    </properties>
-
-    <dependencies>
-        <dependency>
-            <groupId>org.apache.camel</groupId>
-            <artifactId>camel-test-junit5</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>org.testcontainers</groupId>
-            <artifactId>testcontainers</artifactId>
-        </dependency>
-
-        <!-- optional dependencies for running tests -->
-        <dependency>
-            <groupId>org.assertj</groupId>
-            <artifactId>assertj-core</artifactId>
-            <version>${assertj-version}</version>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.logging.log4j</groupId>
-            <artifactId>log4j-slf4j-impl</artifactId>
-            <scope>test</scope>
-        </dependency>
-
-    </dependencies>
-
-    <profiles>
-          <profile>
-            <id>testcontainers-skip-tests</id>
-            <activation>
-                <activeByDefault>true</activeByDefault>
-            </activation>
-            <build>
-                <plugins>
-                    <plugin>
-                        <artifactId>maven-surefire-plugin</artifactId>
-                        <configuration>
-                            <skipTests>true</skipTests>
-                        </configuration>
-                    </plugin>
-                </plugins>
-            </build>
-        </profile>
-        <!-- activate integration test if the docker socket file is accessible 
-->
-        <profile>
-            <id>testcontainers-integration-tests-docker-file</id>
-            <activation>
-                <file>
-                    <exists>/var/run/docker.sock</exists>
-                </file>
-            </activation>
-            <build>
-                <plugins>
-                    <plugin>
-                        <groupId>org.apache.maven.plugins</groupId>
-                        <artifactId>maven-failsafe-plugin</artifactId>
-                        <configuration>
-                            <skipTests>${skipTests}</skipTests>
-                            <systemPropertyVariables>
-                                
<visibleassertions.silence>true</visibleassertions.silence>
-                            </systemPropertyVariables>
-                        </configuration>
-                        <executions>
-                            <execution>
-                                <goals>
-                                    <goal>integration-test</goal>
-                                    <goal>verify</goal>
-                                </goals>
-                            </execution>
-                        </executions>
-                    </plugin>
-                </plugins>
-            </build>
-        </profile>
-
-        <!-- activate integration test if the DOCKER_HOST env var is set -->
-        <profile>
-            <id>testcontainers-integration-tests-docker-env</id>
-            <activation>
-                <property>
-                    <name>env.DOCKER_HOST</name>
-                </property>
-            </activation>
-            <build>
-                <plugins>
-                    <plugin>
-                        <groupId>org.apache.maven.plugins</groupId>
-                        <artifactId>maven-failsafe-plugin</artifactId>
-                        <configuration>
-                            <skipTests>${skipTests}</skipTests>
-                            <systemPropertyVariables>
-                                
<visibleassertions.silence>true</visibleassertions.silence>
-                            </systemPropertyVariables>
-                        </configuration>
-                        <executions>
-                            <execution>
-                                <goals>
-                                    <goal>integration-test</goal>
-                                    <goal>verify</goal>
-                                </goals>
-                            </execution>
-                        </executions>
-                    </plugin>
-                </plugins>
-            </build>
-        </profile>
-    </profiles>
-</project>
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/generated/resources/META-INF/services/org/apache/camel/other.properties
 
b/components/camel-test/camel-testcontainers-junit5/src/generated/resources/META-INF/services/org/apache/camel/other.properties
deleted file mode 100644
index 217b139..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/generated/resources/META-INF/services/org/apache/camel/other.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-# Generated by camel build tools - do NOT edit this file!
-name=testcontainers-junit5
-groupId=org.apache.camel
-artifactId=camel-testcontainers-junit5
-version=3.16.0-SNAPSHOT
-projectName=Camel :: Testcontainers :: JUnit 5
-projectDescription=Camel support for testcontainers with JUnit 5
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/generated/resources/testcontainers-junit5.json
 
b/components/camel-test/camel-testcontainers-junit5/src/generated/resources/testcontainers-junit5.json
deleted file mode 100644
index bb0061a..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/generated/resources/testcontainers-junit5.json
+++ /dev/null
@@ -1,15 +0,0 @@
-{
-  "other": {
-    "kind": "other",
-    "name": "testcontainers-junit5",
-    "title": "Testcontainers JUnit5",
-    "description": "Camel support for testcontainers with JUnit 5",
-    "deprecated": false,
-    "firstVersion": "3.0.0",
-    "label": "testing,java,docker",
-    "supportLevel": "Stable",
-    "groupId": "org.apache.camel",
-    "artifactId": "camel-testcontainers-junit5",
-    "version": "3.16.0-SNAPSHOT"
-  }
-}
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/main/docs/testcontainers-junit5.adoc
 
b/components/camel-test/camel-testcontainers-junit5/src/main/docs/testcontainers-junit5.adoc
deleted file mode 100644
index bb24d32..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/main/docs/testcontainers-junit5.adoc
+++ /dev/null
@@ -1,142 +0,0 @@
-= Testcontainers JUnit5 Component
-:doctitle: Testcontainers JUnit5
-:shortname: testcontainers-junit5
-:artifactid: camel-testcontainers-junit5
-:description: Camel support for testcontainers with JUnit 5
-:since: 3.0
-:supportlevel: Stable
-
-*Since Camel {since}*
-
-Testing camel components is sometime complex because the 3rd party system a 
component interacts with does not provide testing facilities and/or is only 
available as a native application. To reduce this complexity, *Camel 
Testcontainers JUnit 5* extends standard camel test support providing a way to 
create and interact with containerized applications.
-
-In order to define leverage testcontainers, add the following dependency to 
your pom:
-
-[source,xml]
-----
-<dependency>
-    <groupId>org.apache.camel</groupId>
-    <artifactId>camel-testcontainers-junit5</artifactId>
-    <version>x.x.x</version>
-    <!-- use the same version as your Camel core version -->
-    <scope>test</scope>
-</dependency>
-----
-
-[TIP]
-====
-To learn more about testcontainers, please have a look at the 
https://www.testcontainers.org[official documentation]
-====
-
-To leverage testcontainers in your tests, you can use 
`ContainerAwareTestSupport` which is an extension of `CamelTestSupport` which:
-
-- create/destroy containers according to camel context lifecycle
-- inject a custom `PropertiesFunction` to access container specific options 
from properties
-
-
-To create a container you need to override:
-[source, java]
-----
-protected GenericContainer<?> createContainer()
-----
-
-If you need to create more than one container, you can override the following 
method:
-[source, java]
-----
-protected List<GenericContainer<?>> createContainers()
-----
-
-The methods above are invoked before the camel context starts and blocks until 
the containers are reported to be alive. Containers are destroyed once the 
camel context stops.
-
-[source,java]
-.Example
-----
-@Override
-protected GenericContainer<?> createContainer() {
-    return new GenericContainer<>("consul:1.0.7")
-        .withNetworkAliases("myconsul") // <1>
-        .withExposedPorts(8500)
-        .waitingFor(Wait.forLogMessageContaining("Synced node info", 1)) // <2>
-        .withCommand(
-            "agent",
-            "-dev",
-            "-server",
-            "-bootstrap",
-            "-client",
-            "0.0.0.0",
-            "-log-level",
-            "trace"
-        );
-}
-----
-<1> container name/alias
-<2> container startup condition
-
-[IMPORTANT]
-====
-It is important to give a name/alias to the container so you can then use 
properties functions to retrieve information such as container's host and port 
mapping.
-====
-[TIP]
-====
-You may need to wait for some condition to be satisfied before starting your 
test, to do so you need to configure the test suite to wait for such event 
using `GenericContainer.waitingFor`. Testcontainers provide a number of ready 
to use waiting strategy, for more info see the official testcontainers 
documentation.
-====
-
-Camel Testcontainer provides a PropertiesFunction implementation that can be 
used to:
-
-- retrieve the container host with the following syntax 
`container:host:$\{container-name}`
-- retrieve the port mapping with the following syntax 
`container:port:$\{exposed-port}@$\{container-name}`
-
-[source,java]
-.Example
-----
-public class MyTest extends ContainerAwareTestSupport {
-    @Test
-    public void testPropertyPlaceholders() {
-        GenericContainer<?> container = getContainer("myconsul");
-
-        String host = 
context.resolvePropertyPlaceholders("{{container:host:myconsul}}");
-        assertThat(host).isEqualTo(container.getContainerIpAddress());
-
-        String port = 
context.resolvePropertyPlaceholders("{{container:port:8500@myconsul}}");
-        assertThat(port).isEqualTo("" + container.getMappedPort(8500));
-    }
-
-    @Override
-    protected GenericContainer<?> createContainer() {
-        return new GenericContainer<>("consul:1.0.7")
-            .withNetworkAliases("myconsul")
-            .withExposedPorts(8500)
-            .waitingFor(Wait.forLogMessageContaining("Synced node info", 1))
-            .withCommand(
-                "agent",
-                "-dev",
-                "-server",
-                "-bootstrap",
-                "-client",
-                "0.0.0.0",
-                "-log-level",
-                "trace"
-            );
-    }
-}
-----
-
-== Migrating Camel Testcontainers Tests from JUnit 4 to JUnit 5
-Find below some hints to help in migrating camel testcontainers tests from 
JUnit 4 to JUnit 5.
-
-=== Referencing the Camel Testcontainers JUnit5 library in your project
-Projects using `camel-testcontainers` would need to use 
`camel-testcontainers-junit5`. For instance, maven users would update their 
pom.xml file as below:
-----
-<dependency>
-  <groupId>org.apache.camel</groupId>
-  <artifactId>camel-testcontainers-junit5</artifactId>
-  <scope>test</scope>
-</dependency>
-----
-
-Tips: It's possible to run JUnit4 & JUnit5 based camel tests side by side 
including the following dependencies `camel-testcontainers`,
-`camel-testcontainers-junit5` and `junit-vintage-engine`. This configuration 
allows to migrate a camel test at once.
-
-=== Typical migration steps linked to JUnit 5 support in Camel Testcontainers
-* Migration steps linked to xref:test-junit5.adoc[JUnit 5 support in Camel 
Test itself] should have been applied first
-* Imports of `org.apache.camel.test.testcontainers.\*` should be replaced with 
`org.apache.camel.test.testcontainers.junit5.*`
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/ContainerAwareTestSupport.java
 
b/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/ContainerAwareTestSupport.java
deleted file mode 100644
index a80ad80..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/ContainerAwareTestSupport.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * 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.test.testcontainers.junit5;
-
-import java.util.Collections;
-import java.util.List;
-import java.util.concurrent.CopyOnWriteArrayList;
-import java.util.concurrent.TimeUnit;
-
-import org.apache.camel.CamelContext;
-import org.apache.camel.spi.PropertiesComponent;
-import org.apache.camel.test.junit5.CamelTestSupport;
-import org.testcontainers.containers.GenericContainer;
-import org.testcontainers.containers.Network;
-
-/**
- * Tests using this component should switch the test-infra. Please check the 
test-infra module for details and
- * conversion procedures.
- */
-@Deprecated
-public class ContainerAwareTestSupport extends CamelTestSupport {
-    private List<GenericContainer<?>> containers = new 
CopyOnWriteArrayList<>();
-
-    // ******************
-    // Setup
-    // ******************
-
-    @Override
-    protected void setupResources() throws Exception {
-        super.setupResources();
-
-        containers.clear();
-        containers.addAll(createContainers());
-
-        final Network network = containerNetwork();
-        final long timeout = containersStartupTimeout();
-
-        Containers.start(containers, network, timeout);
-    }
-
-    @Override
-    protected void cleanupResources() throws Exception {
-        super.cleanupResources();
-
-        Containers.stop(containers, containerShutdownTimeout());
-    }
-
-    @Override
-    protected CamelContext createCamelContext() throws Exception {
-        final CamelContext context = super.createCamelContext();
-        final PropertiesComponent pc = context.getPropertiesComponent();
-
-        pc.addPropertiesFunction(new ContainerPropertiesFunction(containers));
-
-        return context;
-    }
-
-    // ******************
-    // Containers set-up
-    // ******************
-
-    protected GenericContainer<?> createContainer() {
-        return null;
-    }
-
-    protected List<GenericContainer<?>> createContainers() {
-        GenericContainer<?> container = createContainer();
-
-        return container == null ? Collections.emptyList() : 
Collections.singletonList(container);
-    }
-
-    protected long containersStartupTimeout() {
-        return TimeUnit.MINUTES.toSeconds(1);
-    }
-
-    protected long containerShutdownTimeout() {
-        return TimeUnit.MINUTES.toSeconds(1);
-    }
-
-    protected Network containerNetwork() {
-        return null;
-    }
-
-    // ******************
-    // Helpers
-    // ******************
-
-    protected GenericContainer<?> getContainer(String containerName) {
-        return Containers.lookup(containers, containerName);
-    }
-
-    protected String getContainerHost(String containerName) {
-        return getContainer(containerName).getContainerIpAddress();
-    }
-
-    protected int getContainerPort(String containerName, int originalPort) {
-        return getContainer(containerName).getMappedPort(originalPort);
-    }
-}
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/ContainerPropertiesFunction.java
 
b/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/ContainerPropertiesFunction.java
deleted file mode 100644
index c13a635..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/ContainerPropertiesFunction.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * 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.test.testcontainers.junit5;
-
-import java.util.List;
-
-import org.apache.camel.spi.PropertiesFunction;
-import org.apache.camel.util.ObjectHelper;
-import org.apache.camel.util.StringHelper;
-import org.testcontainers.containers.GenericContainer;
-
-/**
- * Tests using this component should switch the test-infra. Please check the 
test-infra module for details and
- * conversion procedures.
- */
-@Deprecated
-public class ContainerPropertiesFunction implements PropertiesFunction {
-    private final List<GenericContainer<?>> containers;
-
-    public ContainerPropertiesFunction(List<GenericContainer<?>> containers) {
-        this.containers = ObjectHelper.notNull(containers, "Containers");
-    }
-
-    @Override
-    public String getName() {
-        return "container";
-    }
-
-    @Override
-    public String apply(String remainder) {
-        final String type = StringHelper.before(remainder, ":");
-        final String query = StringHelper.after(remainder, ":");
-
-        if (ObjectHelper.isEmpty(type)) {
-            throw new IllegalArgumentException("container function syntax is 
container:type:query");
-        }
-
-        if ("host".equalsIgnoreCase(type)) {
-            String name = StringHelper.after(remainder, ":");
-
-            if (ObjectHelper.isEmpty(name)) {
-                throw new IllegalArgumentException("unable to determine 
container name");
-            }
-
-            return Containers.lookup(containers, StringHelper.after(remainder, 
":")).getContainerIpAddress();
-        }
-
-        if ("port".equalsIgnoreCase(type)) {
-            String port = StringHelper.before(query, "@");
-            String name = StringHelper.after(query, "@");
-
-            if (ObjectHelper.isEmpty(port)) {
-                throw new IllegalArgumentException("unable to determine 
original port");
-            }
-
-            if (ObjectHelper.isEmpty(name)) {
-                throw new IllegalArgumentException("unable to determine 
container name");
-            }
-
-            return Integer.toString(Containers.lookup(containers, 
name).getMappedPort(Integer.parseInt(port)));
-        }
-
-        throw new IllegalArgumentException("Unsupported type: " + type);
-    }
-}
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/Containers.java
 
b/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/Containers.java
deleted file mode 100644
index 32c3fd8..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/Containers.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * 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.test.testcontainers.junit5;
-
-import java.util.List;
-import java.util.concurrent.CountDownLatch;
-import java.util.concurrent.TimeUnit;
-
-import org.apache.camel.util.ObjectHelper;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.testcontainers.containers.GenericContainer;
-import org.testcontainers.containers.Network;
-import org.testcontainers.containers.output.Slf4jLogConsumer;
-
-import static java.util.stream.Collectors.joining;
-
-/**
- * Tests using this component should switch the test-infra. Please check the 
test-infra module for details and
- * conversion procedures.
- */
-@Deprecated
-public final class Containers {
-    private static final Logger LOGGER = 
LoggerFactory.getLogger(Containers.class);
-
-    private Containers() {
-    }
-
-    public static void start(List<GenericContainer<?>> containers, Network 
network, long timeout) throws Exception {
-        final CountDownLatch latch = new CountDownLatch(containers.size());
-
-        for (GenericContainer<?> container : containers) {
-            if (ObjectHelper.isEmpty(container.getNetworkAliases())) {
-                throw new IllegalStateException("Container should have at 
least a network alias");
-            }
-
-            if (network != null) {
-                container.withNetwork(network);
-            }
-
-            // Add custom logger
-            container.withLogConsumer(
-                    new 
Slf4jLogConsumer(LOGGER).withPrefix(container.getNetworkAliases().stream().collect(joining(","))));
-
-            new Thread(() -> {
-                container.start();
-                latch.countDown();
-            }).start();
-        }
-
-        latch.await(timeout, TimeUnit.SECONDS);
-    }
-
-    public static void stop(List<GenericContainer<?>> containers, long 
timeout) throws Exception {
-        final CountDownLatch latch = new CountDownLatch(containers.size());
-
-        for (GenericContainer<?> container : containers) {
-            new Thread(() -> {
-                container.stop();
-                latch.countDown();
-            }).start();
-        }
-
-        latch.await(timeout, TimeUnit.SECONDS);
-    }
-
-    public static GenericContainer<?> lookup(List<GenericContainer<?>> 
containers, String containerName) {
-        for (GenericContainer<?> container : containers) {
-            if (container.getNetworkAliases().contains(containerName)) {
-                return container;
-            }
-        }
-
-        throw new IllegalArgumentException("No container with name " + 
containerName + " found");
-    }
-}
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/Wait.java
 
b/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/Wait.java
deleted file mode 100644
index e24feaa..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/main/java/org/apache/camel/test/testcontainers/junit5/Wait.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * 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.test.testcontainers.junit5;
-
-import java.util.concurrent.TimeUnit;
-import java.util.concurrent.TimeoutException;
-import java.util.function.Predicate;
-
-import com.github.dockerjava.api.DockerClient;
-import org.testcontainers.DockerClientFactory;
-import org.testcontainers.containers.ContainerLaunchException;
-import org.testcontainers.containers.output.OutputFrame;
-import org.testcontainers.containers.output.WaitingConsumer;
-import org.testcontainers.containers.wait.strategy.AbstractWaitStrategy;
-import org.testcontainers.containers.wait.strategy.WaitStrategy;
-import org.testcontainers.utility.LogUtils;
-
-/**
- * Tests using this component should switch the test-infra. Please check the 
test-infra module for details and
- * conversion procedures.
- */
-@Deprecated
-public class Wait extends org.testcontainers.containers.wait.strategy.Wait {
-    /**
-     * Convenience method to return a WaitStrategy for log messages using a 
predicate.
-     *
-     * @param  predicate the predicate to apply to log messages
-     * @param  times     the number of times the pattern is expected
-     * @return           WaitStrategy
-     */
-    public static WaitStrategy forLogPredicate(Predicate<OutputFrame> 
predicate, int times) {
-        return new AbstractWaitStrategy() {
-            @Override
-            protected void waitUntilReady() {
-                final DockerClient client = 
DockerClientFactory.instance().client();
-                final WaitingConsumer waitingConsumer = new WaitingConsumer();
-
-                LogUtils.followOutput(client, 
waitStrategyTarget.getContainerId(), waitingConsumer);
-
-                try {
-                    waitingConsumer.waitUntil(predicate, 
startupTimeout.getSeconds(), TimeUnit.SECONDS, times);
-                } catch (TimeoutException e) {
-                    throw new ContainerLaunchException("Timed out");
-                }
-            }
-        };
-    }
-
-    /**
-     * Convenience method to return a WaitStrategy for log messages.
-     *
-     * @param  text  the text to find
-     * @param  times the number of times the pattern is expected
-     * @return       WaitStrategy
-     */
-    public static WaitStrategy forLogMessageContaining(String text, int times) 
{
-        return forLogPredicate(u -> u.getUtf8String().contains(text), times);
-    }
-}
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/test/java/org/apache/camel/test/testcontainers/junit5/ContainerAwareTestSupportIT.java
 
b/components/camel-test/camel-testcontainers-junit5/src/test/java/org/apache/camel/test/testcontainers/junit5/ContainerAwareTestSupportIT.java
deleted file mode 100644
index ebf4254..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/test/java/org/apache/camel/test/testcontainers/junit5/ContainerAwareTestSupportIT.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * 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.test.testcontainers.junit5;
-
-import org.assertj.core.api.Assertions;
-import org.junit.jupiter.api.Test;
-import org.testcontainers.containers.GenericContainer;
-
-@SuppressWarnings("deprecation")
-public class ContainerAwareTestSupportIT extends ContainerAwareTestSupport {
-    @Test
-    public void testPropertyPlaceholders() {
-        final GenericContainer<?> container = getContainer("myconsul");
-
-        final String host = 
context.resolvePropertyPlaceholders("{{container:host:myconsul}}");
-        
Assertions.assertThat(host).isEqualTo(container.getContainerIpAddress());
-
-        final String port = 
context.resolvePropertyPlaceholders("{{container:port:8500@myconsul}}");
-        Assertions.assertThat(port).isEqualTo("" + 
container.getMappedPort(8500));
-    }
-
-    @Override
-    protected GenericContainer<?> createContainer() {
-        return new GenericContainer<>("consul:1.6.2")
-                .withNetworkAliases("myconsul")
-                .withExposedPorts(8500)
-                .waitingFor(Wait.forLogMessageContaining("Synced node info", 
1))
-                .withCommand(
-                        "agent",
-                        "-dev",
-                        "-server",
-                        "-bootstrap",
-                        "-client",
-                        "0.0.0.0",
-                        "-log-level",
-                        "trace");
-    }
-
-}
diff --git 
a/components/camel-test/camel-testcontainers-junit5/src/test/resources/log4j2.properties
 
b/components/camel-test/camel-testcontainers-junit5/src/test/resources/log4j2.properties
deleted file mode 100644
index 7db2ad4..0000000
--- 
a/components/camel-test/camel-testcontainers-junit5/src/test/resources/log4j2.properties
+++ /dev/null
@@ -1,30 +0,0 @@
-## ---------------------------------------------------------------------------
-## 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.
-## ---------------------------------------------------------------------------
-
-appender.file.type = File
-appender.file.name = file
-appender.file.fileName = target/camel-testcontainers.log
-appender.file.layout.type = PatternLayout
-appender.file.layout.pattern = %d %-5p %c{1} - %m %n
-appender.out.type = Console
-appender.out.name = out
-appender.out.layout.type = PatternLayout
-appender.out.layout.pattern = [%30.30t] %-30.30c{1} %-5p %m%n
-logger.spring.name = org.apache.camel.test.testcontainers
-logger.spring.level = DEBUG
-rootLogger.level = INFO
-rootLogger.appenderRef.file.ref = file
diff --git a/components/camel-test/pom.xml b/components/camel-test/pom.xml
index d5ca121..a21be85 100644
--- a/components/camel-test/pom.xml
+++ b/components/camel-test/pom.xml
@@ -39,7 +39,6 @@
         <module>camel-test-junit5</module>
         <module>camel-test-spring-junit5</module>
         <module>camel-testcontainers</module>
-        <module>camel-testcontainers-junit5</module>
     </modules>
 
 </project>
diff --git 
a/docs/components/modules/others/examples/json/testcontainers-junit5.json 
b/docs/components/modules/others/examples/json/testcontainers-junit5.json
deleted file mode 120000
index 80d56f4..0000000
--- a/docs/components/modules/others/examples/json/testcontainers-junit5.json
+++ /dev/null
@@ -1 +0,0 @@
-../../../../../../components/camel-test/camel-testcontainers-junit5/src/generated/resources/testcontainers-junit5.json
\ No newline at end of file
diff --git a/docs/components/modules/others/pages/testcontainers-junit5.adoc 
b/docs/components/modules/others/pages/testcontainers-junit5.adoc
deleted file mode 120000
index 92c21ed..0000000
--- a/docs/components/modules/others/pages/testcontainers-junit5.adoc
+++ /dev/null
@@ -1 +0,0 @@
-../../../../../components/camel-test/camel-testcontainers-junit5/src/main/docs/testcontainers-junit5.adoc
\ No newline at end of file
diff --git a/docs/user-manual/modules/ROOT/pages/testing.adoc 
b/docs/user-manual/modules/ROOT/pages/testing.adoc
index d9709e6..8c2aee7 100644
--- a/docs/user-manual/modules/ROOT/pages/testing.adoc
+++ b/docs/user-manual/modules/ROOT/pages/testing.adoc
@@ -33,8 +33,6 @@ class for all your configuration and routing without.
 
 |xref:test-infra.adoc[camel-test-infra] | *Camel Test Infra*: Camel Test Infra 
is a set of modules that leverage Test Containers and abstract the provisioning 
and execution of test infrastructure. It is the successor of the 
camel-testcontainers components.
 
-|xref:components:others:testcontainers-junit5.adoc[camel-testcontainers-junit5]
 | *JUnit 5 (deprecated)*: Camel Testcontainers extends standard camel test 
support providing a way to create and interact with containerized applications.
-
 |=======================================================================
 
 NOTE: If you are using Camel Quarkus then you can find information in

Reply via email to