You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "ppalaga (via GitHub)" <gi...@apache.org> on 2023/05/12 14:10:13 UTC

[GitHub] [camel-quarkus] ppalaga opened a new issue, #4893: CouchDb test: Timed out waiting for container port to open

ppalaga opened a new issue, #4893:
URL: https://github.com/apache/camel-quarkus/issues/4893

   I see this on two of my Fedora machines (F34 and F38). 
   
   ```
   [INFO] Running org.apache.camel.quarkus.component.couchdb.it.CouchdbTest
   ...
   2023-05-12 15:52:07,802 INFO  [org.tes.uti.ImageNameSubstitutor] (pool-2-thread-1) Image name substitution will be performed by: DefaultImageNameSubstitutor (composite of 'ConfigurationFileImageNameSubstitutor' and 'PrefixingImageNameSubstitutor')
   2023-05-12 15:52:07,811 INFO  [org.tes.doc.DockerClientProviderStrategy] (pool-2-thread-1) Loaded org.testcontainers.dockerclient.UnixSocketClientProviderStrategy from ~/.testcontainers.properties, will try it first
   2023-05-12 15:52:08,009 INFO  [org.tes.doc.DockerClientProviderStrategy] (pool-2-thread-1) Found Docker environment with local Unix socket (unix:///var/run/docker.sock)
   2023-05-12 15:52:08,010 INFO  [org.tes.DockerClientFactory] (pool-2-thread-1) Docker host IP address is localhost
   2023-05-12 15:52:08,020 INFO  [org.tes.DockerClientFactory] (pool-2-thread-1) Connected to docker: 
     Server Version: 23.0.6
     API Version: 1.42
     Operating System: Fedora Linux 38 (KDE Plasma)
     Total Memory: 64204 MB
   2023-05-12 15:52:08,042 INFO  [๐Ÿณ .3.4]] (pool-2-thread-1) Creating container for image: testcontainers/ryuk:0.3.4
   2023-05-12 15:52:08,045 INFO  [org.tes.uti.RegistryAuthLocator] (pool-2-thread-1) Failure when attempting to lookup auth config. Please ignore if you don't have images in an authenticated registry. Details: (dockerImageName: testcontainers/ryuk:0.3.4, configFile: /home/ppalaga/.docker/config.json. Falling back to docker-java default behaviour. Exception message: /home/ppalaga/.docker/config.json (No such file or directory)
   2023-05-12 15:52:08,135 INFO  [๐Ÿณ .3.4]] (pool-2-thread-1) Container testcontainers/ryuk:0.3.4 is starting: a9ae20574bf57acc32c3e30271a257d41eec81e149c1dbd4474e388929c52f32
   2023-05-12 15:52:08,398 INFO  [๐Ÿณ .3.4]] (pool-2-thread-1) Container testcontainers/ryuk:0.3.4 started in PT0.374221377S
   2023-05-12 15:52:08,402 INFO  [org.tes.uti.RyukResourceReaper] (pool-2-thread-1) Ryuk started - will monitor and terminate Testcontainers containers on JVM exit
   2023-05-12 15:52:08,402 INFO  [org.tes.DockerClientFactory] (pool-2-thread-1) Checking the system...
   2023-05-12 15:52:08,402 INFO  [org.tes.DockerClientFactory] (pool-2-thread-1) โœ”๏ธŽ Docker server version should be at least 1.6.0
   2023-05-12 15:52:08,403 INFO  [๐Ÿณ .3.1]] (pool-2-thread-1) Creating container for image: couchdb:2.3.1
   2023-05-12 15:52:08,446 INFO  [๐Ÿณ .3.1]] (pool-2-thread-1) Container couchdb:2.3.1 is starting: ab365903cd7cc90445c529a61b9c4a2ba865be2976dc35affdf21ddacfb374aa
   2023-05-12 15:53:08,671 ERROR [๐Ÿณ .3.1]] (pool-2-thread-1) Could not start container: org.testcontainers.containers.ContainerLaunchException: Timed out waiting for container port to open (localhost ports: [32769] should be listening)
           at org.testcontainers.containers.wait.strategy.HostPortWaitStrategy.waitUntilReady(HostPortWaitStrategy.java:102)
           at org.testcontainers.containers.wait.strategy.AbstractWaitStrategy.waitUntilReady(AbstractWaitStrategy.java:52)
           at org.testcontainers.containers.GenericContainer.waitUntilContainerStarted(GenericContainer.java:953)
           at org.testcontainers.containers.GenericContainer.tryStart(GenericContainer.java:485)
           at org.testcontainers.containers.GenericContainer.lambda$doStart$0(GenericContainer.java:344)
           at org.rnorth.ducttape.unreliables.Unreliables.retryUntilSuccess(Unreliables.java:81)
           at org.testcontainers.containers.GenericContainer.doStart(GenericContainer.java:334)
           at org.testcontainers.containers.GenericContainer.start(GenericContainer.java:322)
           at org.apache.camel.quarkus.component.couchdb.it.CouchdbTestResource.start(CouchdbTestResource.java:48)
           at io.quarkus.test.common.TestResourceManager$TestResourceEntryRunnable.run(TestResourceManager.java:492)
           at java.base/java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1804)
           at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
           at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
           at java.base/java.lang.Thread.run(Thread.java:833)
   
   2023-05-12 15:53:08,694 ERROR [๐Ÿณ .3.1]] (pool-2-thread-1) Log output from the failed container:
   ****************************************************
   WARNING: CouchDB is running in Admin Party mode.
            This will allow anyone with access to the
            CouchDB port to access your database. In
            Docker's default configuration, this is
            effectively any other container on the same
            system.
            Use "-e COUCHDB_USER=admin -e COUCHDB_PASSWORD=password"
            to set it in "docker run".
   ****************************************************
   
   [ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 62.749 s <<< FAILURE! - in org.apache.camel.quarkus.component.couchdb.it.CouchdbTest
   [ERROR] crudShouldSucceed  Time elapsed: 0.009 s  <<< ERROR!
   java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
           at io.quarkus.test.junit.QuarkusTestExtension.throwBootFailureException(QuarkusTestExtension.java:625)
           at io.quarkus.test.junit.QuarkusTestExtension.interceptTestClassConstructor(QuarkusTestExtension.java:696)
           at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.lambda$invoke$0(InterceptingExecutableInvoker.java:93)
           at org.junit.jupiter.engine.execution.InvocationInterceptorChain$InterceptedInvocation.proceed(InvocationInterceptorChain.java:106)
           at org.junit.jupiter.api.extension.InvocationInterceptor.interceptTestClassConstructor(InvocationInterceptor.java:73)
           at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.lambda$invoke$0(InterceptingExecutableInvoker.java:93)
           at org.junit.jupiter.engine.execution.InvocationInterceptorChain$InterceptedInvocation.proceed(InvocationInterceptorChain.java:106)
           at org.junit.jupiter.engine.execution.InvocationInterceptorChain.proceed(InvocationInterceptorChain.java:64)
           at org.junit.jupiter.engine.execution.InvocationInterceptorChain.chainAndInvoke(InvocationInterceptorChain.java:45)
           at org.junit.jupiter.engine.execution.InvocationInterceptorChain.invoke(InvocationInterceptorChain.java:37)
           at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.invoke(InterceptingExecutableInvoker.java:92)
           at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker.invoke(InterceptingExecutableInvoker.java:62)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.invokeTestClassConstructor(ClassBasedTestDescriptor.java:363)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.instantiateTestClass(ClassBasedTestDescriptor.java:310)
           at org.junit.jupiter.engine.descriptor.ClassTestDescriptor.instantiateTestClass(ClassTestDescriptor.java:79)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.instantiateAndPostProcessTestInstance(ClassBasedTestDescriptor.java:286)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.lambda$testInstancesProvider$4(ClassBasedTestDescriptor.java:278)
           at java.base/java.util.Optional.orElseGet(Optional.java:364)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.lambda$testInstancesProvider$5(ClassBasedTestDescriptor.java:277)
           at org.junit.jupiter.engine.execution.TestInstancesProvider.getTestInstances(TestInstancesProvider.java:31)
           at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.lambda$prepare$0(TestMethodTestDescriptor.java:105)
           at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
           at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.prepare(TestMethodTestDescriptor.java:104)
           at org.junit.jupiter.engine.descriptor.TestMethodTestDescriptor.prepare(TestMethodTestDescriptor.java:68)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$prepare$2(NodeTestTask.java:123)
           at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.prepare(NodeTestTask.java:123)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:90)
           at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
           at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155)
           at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
           at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
           at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
           at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
           at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155)
           at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141)
           at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139)
           at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95)
           at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.submit(SameThreadHierarchicalTestExecutorService.java:35)
           at org.junit.platform.engine.support.hierarchical.HierarchicalTestExecutor.execute(HierarchicalTestExecutor.java:57)
           at org.junit.platform.engine.support.hierarchical.HierarchicalTestEngine.execute(HierarchicalTestEngine.java:54)
           at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:147)
           at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:127)
           at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:90)
           at org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:55)
           at org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:102)
           at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:54)
           at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:114)
           at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:86)
           at org.junit.platform.launcher.core.DefaultLauncherSession$DelegatingLauncher.execute(DefaultLauncherSession.java:86)
           at org.junit.platform.launcher.core.SessionPerRequestLauncher.execute(SessionPerRequestLauncher.java:53)
           at org.apache.maven.surefire.junitplatform.JUnitPlatformProvider.invokeAllTests(JUnitPlatformProvider.java:150)
           at org.apache.maven.surefire.junitplatform.JUnitPlatformProvider.invoke(JUnitPlatformProvider.java:124)
           at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:384)
           at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:345)
           at org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:126)
           at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:418)
   Caused by: java.lang.reflect.InvocationTargetException
           at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
           at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.base/java.lang.reflect.Method.invoke(Method.java:568)
           at io.quarkus.test.junit.QuarkusTestExtension.doJavaStart(QuarkusTestExtension.java:237)
           at io.quarkus.test.junit.QuarkusTestExtension.ensureStarted(QuarkusTestExtension.java:592)
           at io.quarkus.test.junit.QuarkusTestExtension.beforeAll(QuarkusTestExtension.java:640)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.lambda$invokeBeforeAllCallbacks$12(ClassBasedTestDescriptor.java:395)
           at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.invokeBeforeAllCallbacks(ClassBasedTestDescriptor.java:395)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.before(ClassBasedTestDescriptor.java:211)
           at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.before(ClassBasedTestDescriptor.java:84)
           at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:148)
           ... 36 more
   Caused by: java.util.concurrent.CompletionException: java.lang.RuntimeException: Unable to start Quarkus test resource class org.apache.camel.quarkus.component.couchdb.it.CouchdbTestResource
           at java.base/java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:315)
           at java.base/java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:320)
           at java.base/java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1807)
           at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
           at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
           at java.base/java.lang.Thread.run(Thread.java:833)
   Caused by: java.lang.RuntimeException: Unable to start Quarkus test resource class org.apache.camel.quarkus.component.couchdb.it.CouchdbTestResource
           at io.quarkus.test.common.TestResourceManager$TestResourceEntryRunnable.run(TestResourceManager.java:498)
           at java.base/java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1804)
           ... 3 more
   Caused by: java.lang.RuntimeException: org.testcontainers.containers.ContainerLaunchException: Container startup failed
           at org.apache.camel.quarkus.component.couchdb.it.CouchdbTestResource.start(CouchdbTestResource.java:54)
           at io.quarkus.test.common.TestResourceManager$TestResourceEntryRunnable.run(TestResourceManager.java:492)
           ... 4 more
   Caused by: org.testcontainers.containers.ContainerLaunchException: Container startup failed
           at org.testcontainers.containers.GenericContainer.doStart(GenericContainer.java:349)
           at org.testcontainers.containers.GenericContainer.start(GenericContainer.java:322)
           at org.apache.camel.quarkus.component.couchdb.it.CouchdbTestResource.start(CouchdbTestResource.java:48)
           ... 5 more
   Caused by: org.rnorth.ducttape.RetryCountExceededException: Retry limit hit with exception
           at org.rnorth.ducttape.unreliables.Unreliables.retryUntilSuccess(Unreliables.java:88)
           at org.testcontainers.containers.GenericContainer.doStart(GenericContainer.java:334)
           ... 7 more
   Caused by: org.testcontainers.containers.ContainerLaunchException: Could not create/start container
           at org.testcontainers.containers.GenericContainer.tryStart(GenericContainer.java:542)
           at org.testcontainers.containers.GenericContainer.lambda$doStart$0(GenericContainer.java:344)
           at org.rnorth.ducttape.unreliables.Unreliables.retryUntilSuccess(Unreliables.java:81)
           ... 8 more
   Caused by: org.testcontainers.containers.ContainerLaunchException: Timed out waiting for container port to open (localhost ports: [32769] should be listening)
           at org.testcontainers.containers.wait.strategy.HostPortWaitStrategy.waitUntilReady(HostPortWaitStrategy.java:102)
           at org.testcontainers.containers.wait.strategy.AbstractWaitStrategy.waitUntilReady(AbstractWaitStrategy.java:52)
           at org.testcontainers.containers.GenericContainer.waitUntilContainerStarted(GenericContainer.java:953)
           at org.testcontainers.containers.GenericContainer.tryStart(GenericContainer.java:485)
           ... 10 more
   
   [INFO] 
   [INFO] Results:
   [INFO] 
   [ERROR] Errors: 
   [ERROR]   CouchdbTest.crudShouldSucceed ยป Runtime java.lang.reflect.InvocationTargetExce...
   [INFO] 
   [ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
   ```
   
   It must be something local to my machines, because the test is passing on CI.
   Other testcontainers tests are passing fine on those machines.
   
   While testcontainers is waiting for the container to boot, I can see it being up in the output of `docker ps`
   I can also connect to both IPv4 and IPv6 mapped ports of the container using `nc -vn 127.0.0.1 <port>` or `nc -vn ::1 <port>` respectively. 
   Turning off firewalld does not change anything.
   
   Could please anybody confirm that it works for her/him on some recent Fedora?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [camel-quarkus] ppalaga commented on issue #4893: CouchDb test: Timed out waiting for container port to open

Posted by "ppalaga (via GitHub)" <gi...@apache.org>.
ppalaga commented on issue #4893:
URL: https://github.com/apache/camel-quarkus/issues/4893#issuecomment-1568068213

   > I test on my Fedora 36 locally and it works.
   
   Thanks @zhfeng, nice to know.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [camel-quarkus] zhfeng commented on issue #4893: CouchDb test: Timed out waiting for container port to open

Posted by "zhfeng (via GitHub)" <gi...@apache.org>.
zhfeng commented on issue #4893:
URL: https://github.com/apache/camel-quarkus/issues/4893#issuecomment-1562174632

   I test on my Fedora 36 locally and it works.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org