You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On our slow Jenkins Ryuk doesn't start consistently in 5 seconds hardcoded in ResourceReaper#start:
// We need to wait before we can start any containers to make sure that we delete them
if (!ryukScheduledLatch.await(5, TimeUnit.SECONDS)) {
throw new IllegalStateException("Can not connect to Ryuk");
}
Which leads to the following stacktraces:
WARN # org.testcontainers.utility.ResourceReaper.lambda$start$2 Can not connect to Ryuk at localhost:35047
java.net.SocketException: Broken pipe (Write failed)
at java.net.SocketOutputStream.socketWrite0(Native Method) ~[?:1.8.0_152]
at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:111) ~[?:1.8.0_152]
at java.net.SocketOutputStream.write(SocketOutputStream.java:134) ~[?:1.8.0_152]
at org.testcontainers.utility.ResourceReaper.lambda$start$2(ResourceReaper.java:136) ~[testcontainers-1.6.0.jar:?]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_152]
WARN # org.testcontainers.utility.ResourceReaper.lambda$start$2 Can not connect to Ryuk at localhost:35047
java.net.SocketException: Connection reset
at java.net.SocketInputStream.read(SocketInputStream.java:210) ~[?:1.8.0_152]
at java.net.SocketInputStream.read(SocketInputStream.java:141) ~[?:1.8.0_152]
at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[?:1.8.0_152]
at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[?:1.8.0_152]
at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[?:1.8.0_152]
at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[?:1.8.0_152]
at java.io.BufferedReader.fill(BufferedReader.java:161) ~[?:1.8.0_152]
at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[?:1.8.0_152]
at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[?:1.8.0_152]
at org.testcontainers.utility.ResourceReaper.lambda$start$2(ResourceReaper.java:139) ~[testcontainers-1.6.0.jar:?]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_152]
[...]
Caused by: java.lang.IllegalStateException: Can not connect to Ryuk
at org.testcontainers.utility.ResourceReaper.start(ResourceReaper.java:158) ~[testcontainers-1.6.0.jar:?]
at org.testcontainers.DockerClientFactory.client(DockerClientFactory.java:116) ~[testcontainers-1.6.0.jar:?]
at org.testcontainers.containers.GenericContainer.<init>(GenericContainer.java:126) ~[testcontainers-1.6.0.jar:?]
To solve this, 2 things could be done:
Increase timeout to more than 10 seconds (or even 1 minute, as the case in
On our slow Jenkins Ryuk doesn't start consistently in 5 seconds hardcoded in
ResourceReaper#start
:Which leads to the following stacktraces:
To solve this, 2 things could be done:
testcontainers-java/core/src/main/java/org/testcontainers/containers/GenericContainer.java
Line 274 in 8558203
If this is resolved, I think you can close #581 , which seem related.
The text was updated successfully, but these errors were encountered: