46

On November 13, 2006, Sun released much of Java as free and open source software, (FOSS), under the terms of the GNU General Public License (GPL). On May 8, 2007, Sun finished the process, making all of Java’s core code available under free software/open-source distribution terms, aside from a small portion of code to which Sun did not hold the copyright.

OpenJDK (Open Java Development Kit) is a free and open source implementation of the Java programming language. It is the result of an effort Sun Microsystems began in 2006. The implementation is licensed under the GNU General Public License (GNU GPL) with a linking exception.

  • Why there are still people who say that Java is not open source or free as in free speech?
  • Am I missing something?
  • Is Java still proprietary?
2
  • 2
  • I don't exactly know wheter only the Sun JVM implementation or even the technology (bytecode) is protected, but all the core libs (java.x.y) are free. So, if anyone creates a different bytecode specs and VM, should use the existing libs for free. Oops, Google did so with Dalvik!
    – ern0
    Dec 10, 2013 at 21:09

3 Answers 3

48

The problem is that in order to call something "Java" you need to get it certified as compliant to the Java spec.

One of the pre-requisites of getting this certification is running you JVM through a test suite - Java Technology Compatibility Kit (TCK). This test suite is NOT open sourced.

So you can build a JVM that behaves in a very Java like way and be completely open source, but, if you want to call it a "Java JVM" you need to buy the certification suite under a non open source license. To many open source advocates this is a complete non starter.

13
  • 7
    That's one of the reasons why Apache Harmony (which was a fairly complete, independent JVM implementation) was stopped. It's a shame really that Sun/Oracle acted this way (and still act this way). What Google did ("almost copy" Java) is probably a direct result of this as well. Oct 24, 2012 at 6:40
  • 1
    Also, the test suite is the Java Platform TCK (there are other TCKs for Java-related techologies as well). Oct 24, 2012 at 7:06
  • 5
    Also, if you build a successful JVM, Oracle might sue you for copyright violation and patent violation. Like they sued Google over Android.
    – MarkJ
    Oct 24, 2012 at 8:52
  • 2
    Is naming law relevant for calling something opensource? I can't create my own browser and call it firefox either. I think for the question the first thing is to understand it ... what is meant by the term "Java" the language spec, the jvm implementation, ... and who is calling it non-open ...
    – johannes
    Oct 24, 2012 at 10:02
  • @johannes -- welcome to open source home of pedants and nitpickers! To many in the open source community these distinctions are important. Witness Apaches abandoning the Harmony project. To others of a more practical bent having a Java Like environment that works is "good enough" like the Dalvik VM at the heart of all Android devices. Oct 24, 2012 at 10:35
15

You should have read this answer before it was removed about which one to use. The main answer stated:

About Java 7, note that JDK7 and OpenJDK7 will have (nearly) identical code base.

Notice the nearly I highlighted.

From the article linked from that answer:

[…] but there is some code where there are open source replacements where we still use the old closed source code. This is primarily in font and graphics rasterization. The old closed source rasterisation code, while being encumbered, has had 10+ years of bug fixing and fine tuning etc and, for any open source replacement to displace that code in productized JDK builds, it would have to be provably as fast and stable and good quality as the existing closed code.

Also, from the Java FAQ:

The Java Development Kit (JDK) is free to download and use for commercial programming, but not to re-distribute.

So, not open source. Just nearly.

Also, even if it were completely open source, the development model and governance would not. That is not a licensing concern, though.

2
  • 2
    "free to download and use but not redistribute" means the software is "not free software", but it can still be "open source". Open source simply implies that you have access to the source code. Free software (as defined by the FSF and others) requires the right to redistribute as well.
    – user
    Oct 24, 2012 at 9:19
  • 6
    @MichaelKjörling The OSI definition certainly requires redestribution rights.
    – luiscubal
    Oct 24, 2012 at 14:37
1

In 1997, Sun Microsystems approached the ECMA to formalize the Java but it soon withdrew from the process. Java standard is actually controlled through Java Community Process.

Although in 2006, most of the Java was released by Sun Microsystems under the terms of GPL but the current official implementation is owned by the Oracle.

As Java lacks any formal standardization recognized by ECMA, ISO/IEC, ANSI, or other third-party standards organization, the Oracle implementation is the defacto standard. However, there are alternative implementations like GNU Compiler for Java, GNU Classpath, IcedTea-Web, etc.

2
  • 7
    -1: Since Java 7, the official reference implementation is the GPL's OpenJDK. Dec 10, 2013 at 23:09
  • 3
    Talk about Java, you will get -1 :( OpenJDK is open source but implementation on Java.com is BCL, as mentioned above and here. First, there is no change to our policy vs Apache Harmony. OCTLA is a program that allows free access to the TCK for OpenJDK-derived implementations licensed under GPL and is only intended for that purpose. Second, the Oracle implementation (what you find on java.com or java.oracle.com) will remain under the BCL license only. Finally, to be completely clear, the OpenJDK source code remains under GPL. Dec 11, 2013 at 10:52

Not the answer you're looking for? Browse other questions tagged or ask your own question.