I'm having problems understanding Java versioning. I'm seeing lots of versions like 1.4.2, 1.5 and 1.6, but I also stumble upon 5.0 and 6.0. I don't understand this versioning or the progression.
I'm pretty new to Java, and I've read a bit about OpenJDK vs Sun, and I think I understand it. Are these versions the difference between OpenJDK and Sun? For example, OpenJDK's latest is 1.6 and Sun's is 6.0?
All these versions are pretty confusing to someone new to Java.
The only difference is the single digit numbers are usually used in conjunction with Java SE 5 and Java EE 6.
The 1.5 and 1.6 versions are what the Java compiler says using
java -version
and sometimes 'the minor release' is used as a version string, like SunOS 5.8 was called Solaris 8 as a product name.Basically throw away the 1. part of the version number.
This is explained (cough) in Java SE Naming and Versions:
And quoting Java SE 6 Platform Name and Version Numbers:
And J2SE Version 1.5.0 or 5.0?:
So, to summarize, the whole naming is a mess but this is finally over and the current platform name is JavaTM Platform, Standard Edition 6 (abbrev. JavaTM SE 6). Two Products are delivered under the platform: the JDKTM 6 and the JRETM 6.
OpenJDK 6 is an open-source implementation of the Java SE 6 Platform, it's different from Sun's JDK.
The versioning is simply a mess:
java -version
) eliminated the traces of the old versioning scheme, but people have gotten used to it and continue to use it colloquially.Both 1.6 and 6 are used to refer to the same version (and similarly for 1.5 and 5).