-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use java client for docker access #1997
Comments
Thanks for the feedback. For now, you need a Docker client CLI ( Calling Docker Engine API without going through the That said, I think one of the main reasons you are asking for this change is because the registry build (
This may be unrelated, but 1.5.0 and 1.5.1 had a serious performance problem due to the issue in our |
I created another issue for the Portus problems. The performance problems are gone. Because the direct interaction with the docker demon is low priority, I close this issue. |
I'll leave this open, as I hope we will move to a Docker library eventually. However, other issues have more priority, so I'm unsure when we'll get to this. |
Hi! FYI I am the current maintainer of https://github.com/docker-java/docker-java We now have an docker-java is used by http://github.com/testcontainers/testcontainers-java and we were happy with the performance of operations, but, if you find any performance issues, please do let me know! |
@bsideup, to use And I see that
|
@chanseokoh per Testcontainers' experience, you only need
Slf4j is a facade (it is important to mention that, for Java, it is an industry standard). You can optionally plug an implementation (like
Famous last words 😂 okay, jokes aside, you could, but I'd advice against. Also, I came here from #2130, and, if you implement your own client, the problem of "I want to provide my own" will stay. |
Yeah I could see the interface as being the right solution here (perhaps the serviceloader mechanic that we use for extensions) |
You mean embedding other dependencies after renaming packages, right? That option doesn't help to us. What we're really trying is to just not use external dependencies as much as possible, as we've beaten by bugs/constraints in external libraries (Apache HttpClient and Google HTTP Client, for example). Often we needed to fix their bugs ourselves, and it has been painful to push them to release the fixes timely.
Maybe I misunderstood, but I don't get how implementing this ourselves could be different; it's like I'm using library A (my own implementation) vs library B ( |
I hope there will be an option to provide an instance, too.
|
Yeah if designed as an interface, I believe service loading would happen only at the plugin level. Having said that, our concern with We're open to accepting design proposals here. As it is not blocking any of our core functionality, it's rather low priority for us. |
Just hit this as we are using gradle docker image to build app, the Docker tooling is not installed. |
Ref: #3571 (comment) |
"jib" does not work well with all docker registries, e.g. Portus does not show images pushed with "jib". "jibDockerBuild" requires a docker image containing a docker binary. That is not appropriate for modern CI processes which require "plain" docker images, e.g. a plain java image for executing gradle.
So it would be nice if "jibDockerBuild" would use a java based docker client instead of expecting docker to be installed. This way a lean "docker in docker" approach can be used to provide the docker unix socket to the "plain" build container. This approach avoids any incompatibilities like e.g. the Portus problem or extremely slow upload speeds (compared to docker push) into GitLab repositories.
E.g. fabric8s docker maven plugin already does it this way. Another way would be using https://github.com/amihaiemil/docker-java-api.
The text was updated successfully, but these errors were encountered: