Teaching with Java is Still Free
It's not easy to wade through the recent licensing changes with Java. It's particularly confusing for folks who use Java for education. Fortunately, it's not rocket science. If you teach with Java, relax, there is nothing to worry. Most of you will continue to use the current free version of Java, but you can also get older ones if you need them.
A few days ago, one of my university colleagues asked me: “I was reading through Oracle's roadmap for Java, which I didn't fully understand, but the general drift seems to be that Java will require a license after 2020. How will this impact our students? How will it impact Scala? Should we be discussing a new language for our introductory courses?”
A very timely question. As it happens, a number of “Java Champions” have worked diligently to put together a document to cut through all that confusion. Here is the fruit of their labor
With the recent changes to Oracle JDK distribution and support, there’s been considerable uncertainty in the Java ecosystem over the rights to use Oracle JDK vs Oracle's OpenJDK builds vs OpenJDK builds from other providers. Working with the various providers, the Java Champions (an independent body of Java experts) have put together a comprehensive Java Is Still Free document on the changes and the choices you have going forward, and yes Java is Still Free!
The Java Is Still Free document has comments and suggested edit access switched on and will periodically be updated to reflect the latest accurate information. It is being disseminated widely and we'd appreciate you sharing this with your colleagues and within your organizations. (Please update the dissemination doc when you do.)"
There is a lot of technical information, not all of interest to educators. Here is what you need to know if you teach with Java.
- You, your students, and your institution, can continue to use Java without paying a fee. You don't have to ask anyone for permission to use Java. You and your students can download Java as you always did.
- It has always been the case that ancient versions of Java are unsupported. If you must have a Java version 7 or below, you can still get them from archives, but you are on your own.
- As always, Oracle offers the latest version of Java for a free download. I can never remember the download site, but http://java.sun.com redirects to it.
- Those versions change more quickly than they used to—every six months instead of roughly every two years.
- For most programming courses, the latest version by Oracle will be fine. There are two exceptions:
- If you use a library or tool that is not compatible with the module system introduced in Java 9, your students should use Java 8. This is not common.
- You might not want your students to use a particular feature. For example, in Java 10 and above, local variable types can be inferred. When you write
var price = 19.95;
the compiler figures out that
price is a
double. Newer versions of Java will add other features that you may not like. If you don't want your students to use those features, and you don't think they listen to your recommendations, stick with Java 8.
- If either of these applies to you, you and your students can download Java 8 at https://adoptopenjdk.net/ Java 8 will be around for a good long time because of the disruptive module system in Java 9.
But what about...
- Scala (and other JVM based languages such as Clojure, Frege, Jython, etc. etc.)
- Free implementations of the JVM continue to exist, so there is no change. Check your favorite JVM based language for details. For example, Scala isn't yet fully working with the Java 9 module system, and it is recommended to use Java 8. It is unlikely that this situation will persist for much longer. But if it does, Java 8 is freely available until 2020 at the Oracle download site, and I predict it will be freely available well beyond that date from elsewhere.
- Applets and Java Web Start
- These technologies have been dying a slow death for many years. Nowadays, end users who wish to configure a browser and a Java plug-in must have considerable technical skills. This entirely negates the benefit of automatic delivery of remote applications. Here are your alternatives:
- Use an installer to package your Java app so that users can install it on their computers. Oracle recommends that you bundle the JRE with your app rather than having users download the JRE separately.
- The Java job market