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 2022/10/10 12:01:15 UTC

[camel-quarkus] 01/07: Set explicit nofile ulimit for activemq-artemis-broker image to make it work also on system with low default nofile ulimit

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

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

commit a3d2b8047cf0a3d9c679f207a22158451c832849
Author: Peter Palaga <pp...@redhat.com>
AuthorDate: Fri Sep 30 13:55:20 2022 +0200

    Set explicit nofile ulimit for activemq-artemis-broker image to make it work also on system with low default nofile ulimit
---
 .../camel/quarkus/test/support/activemq/ActiveMQTestResource.java    | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/integration-tests-support/activemq/src/main/java/org/apache/camel/quarkus/test/support/activemq/ActiveMQTestResource.java b/integration-tests-support/activemq/src/main/java/org/apache/camel/quarkus/test/support/activemq/ActiveMQTestResource.java
index b729d78b21..780099f589 100644
--- a/integration-tests-support/activemq/src/main/java/org/apache/camel/quarkus/test/support/activemq/ActiveMQTestResource.java
+++ b/integration-tests-support/activemq/src/main/java/org/apache/camel/quarkus/test/support/activemq/ActiveMQTestResource.java
@@ -20,6 +20,7 @@ import java.util.Arrays;
 import java.util.LinkedHashMap;
 import java.util.Map;
 
+import com.github.dockerjava.api.model.Ulimit;
 import io.quarkus.test.common.QuarkusTestResourceLifecycleManager;
 import org.testcontainers.containers.GenericContainer;
 import org.testcontainers.containers.wait.strategy.Wait;
@@ -53,7 +54,9 @@ public class ActiveMQTestResource implements QuarkusTestResourceLifecycleManager
                 .withLogConsumer(frame -> System.out.print(frame.getUtf8String()))
                 .withEnv("AMQ_USER", ACTIVEMQ_USERNAME)
                 .withEnv("AMQ_PASSWORD", ACTIVEMQ_PASSWORD)
-                .waitingFor(Wait.forLogMessage(".*AMQ241001.*", 1));
+                .waitingFor(Wait.forLogMessage(".*AMQ241001.*", 1))
+                .withCreateContainerCmdModifier(
+                        cmd -> cmd.getHostConfig().withUlimits(new Ulimit[] { new Ulimit("nofile", 2048L, 2048L) }));
 
         container.start();