真面目なブログはこっち 👉 blog.s64.jp

いろんな `java -version` 表示

必要になったんだけど、いろいろありすぎて困ったのでメモ。ちなみにDocker内でやった。

TL;DR

  • semverじゃないのは常識
  • 実行方法次第では必ずしも3行ではない
  • バージョン表記は3セグメントとも限らず、4セグだったり1セグだったりもする
  • underscoreが入ったりhyphenが入ったりいろいろある
  • バージョン表記のquotesより後に日付が入るパターンもある

OpenJDK

6

java version "1.6.0_38"
OpenJDK Runtime Environment (IcedTea6 1.13.10) (6b38-1.13.10-1~deb7u1)
OpenJDK 64-Bit Server VM (build 23.25-b01, mixed mode)

7

java version "1.7.0_181"
OpenJDK Runtime Environment (IcedTea 2.6.14) (7u181-2.6.14-1~deb8u1)
OpenJDK 64-Bit Server VM (build 24.181-b01, mixed mode)

8

openjdk version "1.8.0_181"
OpenJDK Runtime Environment (build 1.8.0_181-8u181-b13-2~deb9u1-b13)
OpenJDK 64-Bit Server VM (build 25.181-b13, mixed mode)

9

openjdk version "9.0.4"
OpenJDK Runtime Environment (build 9.0.4+12-Debian-4)
OpenJDK 64-Bit Server VM (build 9.0.4+12-Debian-4, mixed mode)

10

openjdk version "10.0.2" 2018-07-17
OpenJDK Runtime Environment (build 10.0.2+13-Debian-2)
OpenJDK 64-Bit Server VM (build 10.0.2+13-Debian-2, mixed mode)

11

openjdk version "11.0.1" 2018-10-16
OpenJDK Runtime Environment (build 11.0.1+13-Debian-2)
OpenJDK 64-Bit Server VM (build 11.0.1+13-Debian-2, mixed mode, sharing)

12

openjdk version "12-ea" 2019-03-19
OpenJDK Runtime Environment (build 12-ea+19)
OpenJDK 64-Bit Server VM (build 12-ea+19, mixed mode, sharing)

Oracle JDK

7

java version "1.7.0_79"
Java(TM) SE Runtime Environment (build 1.7.0_79-b15)
Java HotSpot(TM) 64-Bit Server VM (build 24.79-b02, mixed mode)

8

java version "1.8.0_192"
Java(TM) SE Runtime Environment (build 1.8.0_192-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.192-b12, mixed mode)

9

java version "9.0.1"
Java(TM) SE Runtime Environment (build 9.0.1+11)
Java HotSpot(TM) 64-Bit Server VM (build 9.0.1+11, mixed mode)

10

java version "10.0.1" 2018-04-17
Java(TM) SE Runtime Environment 18.3 (build 10.0.1+10)
Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.1+10, mixed mode)

AdoptOpenJDK

8

Picked up JAVA_TOOL_OPTIONS: -XX:+UnlockExperimentalVMOptions -XX:+UseCGroupMemoryLimitForHeap
openjdk version "1.8.0_192"
OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_192-b12)
OpenJDK 64-Bit Server VM (AdoptOpenJDK)(build 25.192-b12, mixed mode)

9

Picked up JAVA_TOOL_OPTIONS: -XX:+UnlockExperimentalVMOptions -XX:+UseCGroupMemoryLimitForHeap
openjdk version "9.0.4"
OpenJDK Runtime Environment (build 9.0.4+11)
OpenJDK 64-Bit Server VM (build 9.0.4+11, mixed mode)

10

Picked up JAVA_TOOL_OPTIONS: -XX:+UseContainerSupport
openjdk version "10.0.2-adoptopenjdk" 2018-07-17
OpenJDK Runtime Environment (build 10.0.2-adoptopenjdk+13)
OpenJDK 64-Bit Server VM (build 10.0.2-adoptopenjdk+13, mixed mode)

11

Picked up JAVA_TOOL_OPTIONS: -XX:+UseContainerSupport
openjdk version "11.0.1" 2018-10-16
OpenJDK Runtime Environment AdoptOpenJDK (build 11.0.1+13)
OpenJDK 64-Bit Server VM AdoptOpenJDK (build 11.0.1+13, mixed mode)

Zulu

6

openjdk version "1.6.0-119"
OpenJDK Runtime Environment (Zulu 6.22.0.3-linux64) (build 1.6.0-119-b119)
OpenJDK 64-Bit Server VM (Zulu 6.22.0.3-linux64) (build 23.77-b119, mixed mode)

7

openjdk version "1.7.0_201"
OpenJDK Runtime Environment (Zulu 7.25.0.5-linux64) (build 1.7.0_201-b02)
OpenJDK 64-Bit Server VM (Zulu 7.25.0.5-linux64) (build 24.201-b02, mixed mode)

8

openjdk version "1.8.0_192"
OpenJDK Runtime Environment (Zulu 8.33.0.1-linux64) (build 1.8.0_192-b01)
OpenJDK 64-Bit Server VM (Zulu 8.33.0.1-linux64) (build 25.192-b01, mixed mode)

9

openjdk version "9.0.7.1"
OpenJDK Runtime Environment (Zulu build 9.0.7.1+1)
OpenJDK 64-Bit Server VM (Zulu build 9.0.7.1+1, mixed mode)

10

openjdk version "10.0.2" 2018-07-17
OpenJDK Runtime Environment Zulu10.3+5 (build 10.0.2+13)
OpenJDK 64-Bit Server VM Zulu10.3+5 (build 10.0.2+13, mixed mode)

11

openjdk version "11.0.1" 2018-10-16 LTS
OpenJDK Runtime Environment Zulu11.2+3 (build 11.0.1+13-LTS)
OpenJDK 64-Bit Server VM Zulu11.2+3 (build 11.0.1+13-LTS, mixed mode)

Amazon Corretto

8

openjdk version "1.8.0_192"
OpenJDK Runtime Environment (build 1.8.0_192-amazon-corretto-preview-b12)
OpenJDK 64-Bit Server VM (build 25.192-b12, mixed mode)