Docker test container

I am trying to use Docker container as described in https://github.com/dadoonet/testcontainers-java-module-elasticsearch .

The very first thing I do is
ElasticsearchContainer container = new ElasticsearchContainer();
and that errors out - it never even goes to the next line (container.withVersion("6.3.0"); ).
I am not sure really what I am doing and how to do this - I was trying to follow directions you had in there.
BTW, I have windows. Maybe that is the issue?

2018-07-12 11:22:17.053 ERROR 13208 --- [pool-2-thread-1] o.t.s.i.n.u.c.D.rejectedExecution : Failed to submit a listener notification task. Event loop shut down?

java.util.concurrent.RejectedExecutionException: event executor terminated
at org.testcontainers.shaded.io.netty.util.concurrent.SingleThreadEventExecutor.reject(SingleThreadEventExecutor.java:821)
at org.testcontainers.shaded.io.netty.util.concurrent.SingleThreadEventExecutor.offerTask(SingleThreadEventExecutor.java:327)
at org.testcontainers.shaded.io.netty.util.concurrent.SingleThreadEventExecutor.addTask(SingleThreadEventExecutor.java:320)
at org.testcontainers.shaded.io.netty.util.concurrent.SingleThreadEventExecutor.execute(SingleThreadEventExecutor.java:746)
at org.testcontainers.shaded.io.netty.util.concurrent.DefaultPromise.safeExecute(DefaultPromise.java:760)
at org.testcontainers.shaded.io.netty.util.concurrent.DefaultPromise.notifyListeners(DefaultPromise.java:428)
at org.testcontainers.shaded.io.netty.util.concurrent.DefaultPromise.tryFailure(DefaultPromise.java:122)
at org.testcontainers.shaded.io.netty.channel.AbstractChannel$AbstractUnsafe.safeSetFailure(AbstractChannel.java:906)
at org.testcontainers.shaded.io.netty.channel.AbstractChannel$AbstractUnsafe.register(AbstractChannel.java:487)
at org.testcontainers.shaded.io.netty.channel.SingleThreadEventLoop.register(SingleThreadEventLoop.java:80)
at org.testcontainers.shaded.io.netty.channel.SingleThreadEventLoop.register(SingleThreadEventLoop.java:74)
at org.testcontainers.shaded.io.netty.channel.MultithreadEventLoopGroup.register(MultithreadEventLoopGroup.java:86)
at org.testcontainers.shaded.io.netty.bootstrap.AbstractBootstrap.initAndRegister(AbstractBootstrap.java:332)
at org.testcontainers.shaded.io.netty.bootstrap.Bootstrap.doResolveAndConnect(Bootstrap.java:163)
at org.testcontainers.shaded.io.netty.bootstrap.Bootstrap.connect(Bootstrap.java:145)
at org.testcontainers.shaded.io.netty.bootstrap.Bootstrap.connect(Bootstrap.java:126)
at com.github.dockerjava.netty.NettyDockerCmdExecFactory$InetSocketInitializer.connect(NettyDockerCmdExecFactory.java:320)
at com.github.dockerjava.netty.NettyDockerCmdExecFactory.connect(NettyDockerCmdExecFactory.java:220)
at com.github.dockerjava.netty.NettyDockerCmdExecFactory.connect(NettyDockerCmdExecFactory.java:213)
at com.github.dockerjava.netty.NettyDockerCmdExecFactory.access$000(NettyDockerCmdExecFactory.java:157)
at com.github.dockerjava.netty.NettyDockerCmdExecFactory$1.getChannel(NettyDockerCmdExecFactory.java:183)
at com.github.dockerjava.netty.InvocationBuilder.getChannel(InvocationBuilder.java:213)
at com.github.dockerjava.netty.InvocationBuilder.get(InvocationBuilder.java:507)
at com.github.dockerjava.netty.exec.PingCmdExec.execute(PingCmdExec.java:23)
at com.github.dockerjava.netty.exec.PingCmdExec.execute(PingCmdExec.java:10)
at com.github.dockerjava.netty.exec.AbstrSyncDockerCmdExec.exec(AbstrSyncDockerCmdExec.java:21)
at com.github.dockerjava.core.command.AbstrDockerCmd.exec(AbstrDockerCmd.java:35)
at org.testcontainers.dockerclient.DockerClientProviderStrategy.lambda$null$3(DockerClientProviderStrategy.java:169)
at org.rnorth.ducttape.ratelimits.RateLimiter.getWhenReady(RateLimiter.java:51)
at org.testcontainers.dockerclient.DockerClientProviderStrategy.lambda$ping$4(DockerClientProviderStrategy.java:167)
at org.rnorth.ducttape.unreliables.Unreliables.lambda$retryUntilSuccess$0(Unreliables.java:41)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)

java.lang.IllegalStateException: Previous attempts to find a Docker environment failed. Will not retry. Please see logs and check configuration

at org.testcontainers.dockerclient.DockerClientProviderStrategy.getFirstValidStrategy(DockerClientProviderStrategy.java:72)
at org.testcontainers.DockerClientFactory.client(DockerClientFactory.java:99)
at org.testcontainers.containers.GenericContainer.(GenericContainer.java:126)
at org.testcontainers.containers.GenericContainer.(GenericContainer.java:166)
at fr.pilato.elasticsearch.containers.ElasticsearchContainer.(ElasticsearchContainer.java:44)

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.