Skip to content
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

Improved Docker support #3

Open
jabrena opened this issue May 9, 2018 · 1 comment
Open

Improved Docker support #3

jabrena opened this issue May 9, 2018 · 1 comment

Comments

@jabrena
Copy link
Owner

jabrena commented May 9, 2018

http://www.oracle.com/technetwork/java/javase/10-relnote-issues-4108729.html#JDK-8146115
https://blog.docker.com/2018/04/improved-docker-container-integration-with-java-10/

  • JVM now recognizes constraints set by container control groups (cgroups)
  • Java defines a server class machine as having 2 CPUs and 2GB of memory and the default heap size is ¼ of the physical memory
@jabrena
Copy link
Owner Author

jabrena commented May 9, 2018

docker container run -it -m512M --entrypoint bash openjdk:10-jdk
$ docker-java-home/bin/java -XX:+PrintFlagsFinal -version | grep MaxHeapSize
size_t MaxHeapSize                              = 134217728                                {product} {ergonomic}
openjdk version "10" 2018-03-20

docker run -it --cpuset-cpus="1,2,3" openjdk:10-jdk
jshell> Runtime.getRuntime().availableProcessors()
$1 ==> 3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant