Interesting JDK 12 Features to Watch Out For

With the new six month Java release cycle, you should expect cool, new features for developers at a faster rate. I have seen some of the features that you can expect to see in the JDK 12 release next year. You can get the Open JDK 12 early access build and try out these preview features. Let’s take a closer look.

Switch Expressions

For example, you have an enum for the days of the week and you want to use a switch statement to return the number of letters in the string. There are better ways to do this, but we are going to use Switch statements to demonstrate this.

Original Link

Oracle Continues Long-Term Support for Amazon Linux

On October 30, Oracle announced that both OpenJDK 8 and OpenJDK 11 will continue their long-term support for Amazon Linux until June 30, 2023.

Since the announcement that Oracle will no longer provide long-term support for the OpenJDK beginning January 2019, this has sparked a lot of interest in the Java community over support for Amazon Web Services. Oracle and Amazon wanted to reassure devs that OpenJDK 8 and OpenJDK 11 LTS will continue for Amazon Linux until mid-2023.

Original Link

IBM to Acquire Red Hat: A Java-Oriented First Look

Oracle Corporation completed the process of acquiring Sun Microsystems nearly nine years ago. That was big news then, and similarly, the big news was announced on Sunday: IBM and Red Hat have agreed to IBM‘s acquisition of Red Hat. The main IBM page announces "IBM to acquire Red Hat." It then states, "This changes everything." It is likely that this announced acquisition is going to leave many Java developers wondering what kinds of changes are coming to the Java ecosystem.

Since Oracle’s acquisition of Sun Microsystems, Oracle has eliminated multiple products that were formerly competitive products. For example, Oracle still has its JDeveloper IDE but has provided NetBeans (acquired from Sun) to Apache Software Foundation. Oracle has also dropped commercial support for Sun-acquired GlassFish while retaining its WebLogic Java EE application server.

Original Link

Java Annotated Monthly — October 2018

The main news so far has been the release of Java 11. It’s not a large release in terms of new developer functionality since Java 10, but it is the first Long Term Support Release since Java 8. So if you’ve been hanging around on Java 8, now’s the time to look at all new things that made it into Java 9, 10, and 11. Java 11 also removes features. This, like, never happens in Java. Another noteworthy change is that Oracle changed its licensing and support model since Java 8. Read this month’s Annotated Monthly to find out more.

Java License/Support Changes

I covered this topic in the last Annotated Monthly since it was an area of some concern in the community. Since then, the Java Champions (an independent group of experts) have released a comprehensive document covering the situation. I also wrote a summary of what I hope are the most relevant points for developers. Here are other relevant links, if you’re interested.

Original Link

Using Java Flight Recorder With OpenJDK 11

Java Flight Recorder (JFR) used to be a commercial add-on of the Oracle JDK. As it’s been open sourced along with Java Mission Control, everyone using OpenJDK 11 can now troubleshoot their Java apps with this excellent tool for free of charge. JFR, previous proprietary solution, might be lesser known for those relying on previous versions of OpenJDK. Therefore, I thought it was worth writing a fresh post on using JFR with OpenJDK 11.


About the Java Flight Recorder

JFR is a profiling tool used to gather diagnostics and profiling data from a running Java application. Its performance overhead is negligible and that’s usually below 1 percent. For short running apps, this overhead might be above that because JFR requires some warm-up time on the start.

Original Link

Using Java 11 In Production: Important Things To Know

If you stay up to date on news from the Java community, you may have heard that Oracle changed their support model for Java. Some rumors even suggest that we now have to pay to use Java — this is not true!

This topic is quite a complex one since there are a number of overlapping changes that have come together since the release of Java 8. The new, six-monthly release cadence and Oracle’s changes in licensing and support model mean that any organization that deploys a Java application should take this opportunity to look at:

Original Link

Installing OpenJDK 11 on Ubuntu 18.04

OpenJDK 11 was released on September 25, 2018. As this is the first LTS release after version 8, it’s been a long time coming. After having it installed on Ubuntu 18.04 (Bionic Beaver), which comes with a package named openjdk-11-jdk, to my surprise, that was still part of an earlier version (Java 10).

SRU Exception for OpenJDK

The Ubuntu Foundation Team made an SRU exception for OpenJDK. Although version 10 is a non-LTS release, they’ve packaged it as openjdk-11-jdk until OpenJDK 11 goes GA. This choice was based on that assumption that there is a much smaller interface delta between releases 10 and 11 than it would be between 8 and 11.

Original Link

Free Java Production Support on Microsoft Azure and Azure Stack

Thanks to Scott Sellers, President and CEO at Azul Systems, for taking me through their collaboration with Microsoft to make fully compatible and compliant commercial builds of Java SE available for Java developers on Microsoft Azure.

Azul Systems will provide fully-supported Zulu Enterprise builds of OpenJDK for Azure for all long-term support (LTS) versions of Java, starting with Java SE 7, 8, and 11

Original Link

JDK Bug System Timewasters

Several possibilities of a message’s contents crossed my mind when I saw the title of Jesper Wilhelmsson‘s message "Introducing Timewasters" on the OpenJDK JDK-dev mailing list. In the second or so of reading that link, I wondered if the message would be about one of the following topics:

  • People wasting the time of developers working on the JDK
  • People wasting the time of developers sharing ideas and responding to questions on the mailing lists
  • Trivial defect reports or reports of observations that are intentional (not defects)

It turns out that Wilhelmsson‘s topic was far more interesting than those. Wilhelmsson opens the message with these two lines: "As an experiment, we are introducing a new label in JBS, timewaster. The label is used to tag bugs that, for whatever reason, are wasting engineering time." That message provides additional considerations to be made when deciding whether to label a bug in JDK Bug System (JBS) with the "timewaster" label.

Original Link

Java Annotated Monthly: September 2018

Java 11 is due out this month, so you’d expect a lot of Java 11 news. There is some, but the main noise in the community is not around the new language features, but rather Oracle’s updated support model. This is causing panic of the "Oh my goodness Oracle is going to start charging for Java", which is a) not true because actually Oracle has always charged for commercial support and b) not true in the way a lot of people are saying it. Read on for more information.

Java Is Still Free

There’s so much noise, confusion and nonsense out there about Oracle’s changes to support for Java that this deserves its own section. Here’s a short version, more details available in each of the articles:

Original Link

Is Java in Jeopardy?

I wrote an article back in January of this year about Java called Does Java Has a Future? Yes, it Does, and I was so confident in this assumption that I even wrote the answer in the article’s title. It is disappointing for me to write something like this because I may have to change my stance on the matter. I still love Java. It has been (and still is) my favorite programming language since the day I started learning code in 1999. And, there was no looking back since then — I grew up along with it.

Java is still the most widely used enterprise programming language. But, how long will that be? There’s a lot of advances, development, and changes in popularity from Javascript frameworks and other Java alternatives. And, like adding fuel to the fire, the recent developments around Java are not helping. Some of the key developments include:

Original Link

JDK 11: Release Candidate Update and OpenJDK JDK 11 LTS

JDK 11 is scheduled to be released for general availability on Tuesday, 25 September 2018. A 16 August 2018 Mark Reinhold message on the OpenJDK jdk-dev mailing list announced that "JDK 11 is now in the Release Candidate Phase." However, Reinhold provided updated details in a 17 August 2018 message on that same mailing list in which he stated, "We tagged the first Release Candidate build this morning ( jdk-11+27), but since there are some open P1 bugs (, it’s not actually a Release Candidate." Reinhold’s last message concluded with "stay tuned…"

The early access builds are available under "JDK 11 Early-Access Builds," but the most current version available at the time of writing this post (18 August 2018) is Build 26 (2018/8/9).

Original Link

The Will of the [JDK Using] People

In an earlier blog, I wrote about what comes after JDK 8. This examined different factors that might affect people’s decisions about which version of the JDK to move to after JDK 8.

What’s becoming increasingly clear is that there is still considerable confusion about having a new JDK release every six months and how it will impact users and their choice of Java version for deployment.

Original Link

Java Annotated Monthly: August 2018

July was a very quiet month, news-wise, so August is a leisurely perusal of the bits and bobs that are surfacing this summer.


Here is the usual mixed bag of Java-related news, tutorials, and interesting snippets.

Original Link

How to Natively Compile Java Code for Better Startup Time

Microservices and serverless architectures are being implemented as part of the roadmap in most modern solution stacks. Given that Java is still the dominant language for business applications, the need for reducing the startup time for Java is becoming increasingly important. Serverless architectures are one such area that needs faster startup times, and applications hosted on container platforms such as Red Hat Openshift can benefit from both fast Java startup time and a smaller Docker image size.

Let’s see how GraalVM can be beneficial for Java-based programs in terms of speed and size improvements. Surely, these gains are not bound to containers or serverless architectures and can be applied to a variety of use cases.

Original Link

Looking into Java’s Future: Empty Value Types

Although the promising Java value types are not imminent, I still enjoy nosing around occasionally in the OpenJDK Valhalla-dev mailing list to see how things are progressing and to get an idea of what is to come. Admittedly, there are some discussions that are beyond my understanding, given my limited exposure to the terms used and the low-level specifics of some messages. However, occasionally, there are messages and threads that I understand and find interesting. A recent example of this is the “Empty value type ?” thread.

Rémi Forax starts the thread by asking “Is empty value type targeted for LW1?” The example error message included with that question shows as a LinkageError and a ClassFormatError with the message “Value Types do not support zero instance size yet.” The response to this question from Tobias Hartmann says, “No, empty value types are not planned to be supported for LW1.”

Before moving onto the rest of the thread (which is the part that interested me the most), I’ll quickly discuss “LW1.” In a message on that same OpenJDK mailing list called “[lworld] LW1 – ‘Minimal LWorld’,” David Simms states, “we are approaching something ‘usable’ in terms of ‘minimal L World’ (LW1)” and “we will be moving of prototyping to milestone stabilization.” That same message states that the “label” is “lw1.” Along with that, the affected-version and fixed-version are both “repo-valhalla“. In other words, “LW1” is the label used to track bugs and issues related to work on the “minimal L world” implementation. You can reference John Rose’s 19 November 2017 message, “abandon all U-types, welcome to L-world (or, what I learned in Burlington)” for an introduction to the “L World” term and what it means in terms of value types.

Returning to the “Empty value type?” thread, Kirk Pepperdine asked a question that also occurred to me, “How can a value type be empty?” He added, “What is an empty integer? An empty string?” He said he was “just curious” and now I am too. Here is a summary of the informative responses:

  • Rémi Forax: “type [that] represents the absence of value like unit, void, or bottom
  • Rémi Forax: “type that represents the result of a throw”
  • Rémi Forax: “type that allows HashSet<E> to be defined as HashMap<E,Empty>
    • Brian Goetz‘s message elaborates on the value of this, “Zero-length values can be quite useful, just not directly. Look at the current implementations of Set that delegate to HashMap; all that wasted space. When we have specialized generics, they can specialize to HashMap<T, empty>, and that space gets squeezed away to zero.”
  • Rémi Forax: “transformative type like a marker type that separate arguments” (see the message for example of this one)

I also liked the final (as of this writing) Kirk Pepperdine message on that thread where he summarizes, “Feels like a value type version of null.”

Incidentally, there are some other interesting messages and threads in the June 2018 Archives of the Valhalla-dev mailing list. Here are some of them:

I look forward to one day being able to apply value types in my everyday Java code. Until then, it is interesting to think about and also to see how much work is going into making these value types.

Original Link

The Next Generation of Java Application Deployments

A lot is going on in the Java world. So, let’s have a look at where we currently are.

Oracle Discontinues Java Web Start With Java 11

After discontinuing the Applet technology, which required browser plug-ins, Oracle has announced that they will also discontinue the Java Web Start technology.

Java Web Start, however, was a great way to easily deploy Java applications. It made sure that Java application deployments didn’t fall too far behind the instant deployment feature of web applications — a point which already allows many companies to choose web applications over Java-based applications.

With Java Web Start gone, it will become harder, once again, to compete with web applications, if we don’t find a good alternative.

Oracle Changed to a Biannual Major Java Release Cadence

Every 6 months, there will be a new “major” Java version, though the term “major” likely won’t be used anymore and differences will be smaller than the 2-3 year cadence (see Java 8 -> Java 9 vs Java 9 -> Java 10).

With every “major” release, the support of the previous release seems to be discontinued.

Every three years there will be an LTS (Long Term Support) version, starting with Java 11 targeted for September 2018 (there is a small video and an FAQ about this from Oracle).

As far as I understand, you will need to buy this LTS. If you don’t, then it’s recommended to upgrade to the next major version or find another distributor that provides updates (more on this below).

Interestingly, and to some surprise, the long-awaited Java SE 9 release with the new module system didn’t become an LTS version and already has been superseded by Java SE 10.

Oracle also mentions that developers often package the JRE with their applications nowadays. End users should not need to install a JRE anymore.

Oracle and OpenJDK Binaries

While Sun started to open source the JDK with the OpenJDK project back in 2006 and Oracle continued this process, there are still some differences between the OpenJDK builds and the Oracle Java builds.

Now, Oracle plans to ship OpenJDK binaries for non-LTS releases, and with this shift, they also plan to finally close those technical differences that currently still exist.

Once these differences are closed, this will make projects such as AdoptOpenJDK much more appealing, as it seems they will provide free updates for LTS versions in the future.

Modular JRE and JLink

Together, with the JPMS (Java Platform Module System), which modularizes the JRE and can be used to modularize applications, Java 9 introduced a new tool called JLink.

JLink allows you to create custom runtime images that only consist of your application modules and those JRE modules that your application requires. The result is likely a smaller runtime image, which uses fewer resources than a default JRE. This should also make Java more appealing to IoT devices.


Since JavaFX 2.2 and Java SE 7 update 6, JavaFX has been included in Oracle’s JDK. With JavaFX 8 and Java SE 8, the version has been aligned. Now, JavaFX has become available on the default classpath.

Recently, Oracle announced (see the link at the top) that, with Java SE 11, JavaFX will be removed again from the JDK.

With a modularized JRE, it might be more natural to let feature modules have their own cycles.

But, since JavaFX also includes native parts, it seems to me WORA (Write Once, Run Anywhere) will become a bit trickier — at least the packaging part of JavaFX applications.

Please read on for a possible solution.

The Java Packager Tool

JavaFX also introduced a new tool to create platform-specific native packages with an embedded JRE. With JavaFX 8, the tool has been added to the JDK as the javapackager tool.

Since Java SE 9, the javapackager tool integrates with the jlink tool.

In Java SE 11, the javapackager tool will be removed again from the JDK along with JavaFX.

There is a JEP request (JDK Enhancement Proposal) for a new jpackager tool. While I think we do need a tool such as javapackager/ jpackager, javapackager, and the proposed jpackager, they also have some major drawbacks:

  • No cross-compilation support — You have to create the native packages on the target platforms, e.g. MSI-packages on Windows and deb-packages on Linux. Creating a one-click release pipeline is non-trivial.
  • Platform-specific configurations — Each native package has slightly different requirements.
  • No automatic security updates — The users have to rely on the application vendors to ship a new application version that contains a JRE with the latest security fixes (though not all security bugs might affect individual applications in the same way).
  • Expensively managed deployments — In heavily managed enterprises, where the average users don’t have local admin rights and can’t install applications themselves, the processes of application deployments tend to get very expensive (up to several thousand CHF per deployment). This is another reason why enterprises nowadays tend to either Java Web Start or to web applications.
  • Slow managed deployments — In these heavily managed enterprises, deployments also tend to be slow and can take up to several weeks until the application is deployed to the user machine. This also makes it hard to coordinate frontend deployments with backend deployments and is definitely not DevOps-friendly. This is yet another reason why enterprises nowadays tend to either Java Web Start or to web applications.

Drombler JStore

Given the above-mentioned issues with tools such as javapackager/ jpackager, which create application packages with an embedded JRE, I don’t think this is the solution for the majority of Java applications.

On the other hand, I think that we should not require any more from end-users to pre-install a JRE, which likely doesn’t fit for all applications anyway. However, it’s unlikely that Oracle will provide another solution other than the jpackager.

If we need something different, then it will have to be community driven. So, I’m proposing here a new deployment model with the working title (likely to change): Drombler JStoreAt the core of this deployment model is a new application store with first-class support for Java applications.

In general, most applications should be able to define a platform-independent package that also describes the dependencies to some managed native components, such as the JRE

The tooling will then make sure that the required native components are available on the end-user machine. The tooling will also configure the environment for the process which starts the application.

The currently proposed solution consists of 4 major software parts.

I’ve already written a PoC (Proof of Concept) for each of those, which I think can serve as a starting point. Please note that everything is still subject to change.

  • Drombler JStore Client Agent:
    • Current goals:
      • Headless background service
      • Targets: end-user devices (desktops, NAS, IoT devices,…)
      • Download and update applications from Drombler JStore
      • Download and update applications using a JNLP-like file
      • Download and update native components:
        • JREs (supporting multiple parallel major version installations)
        • Custom runtimes created by JLink (supporting multiple parallel major version installations)
        • JavaFX native components?
        • Other native components, e.g. SWT?
      • Support Security Manager
      • Start applications in a configured environment
      • OS integration:
        • Desktop shortcuts
        • URL protocol registration
        • Run as native OS service/ deamon
    • PoC:
      • Access a first Drombler JStore REST service
      • Download a JRE from Oracle
    • GitHub:
  • Drombler JStore:
    • Current goals:
      • A free service (backend) run by Drombler
      • Provide access to applications/application updates
      • Provide access to native components and updates (JREs etc.)
      • Search applications
      • Rate applications
      • Comment on applications
      • Register vendors
      • Provide vendor contact options
    • PoC:
      • A first deployed REST service is available (likely to change)
    • Swagger:
  • Drombler JStore Client:
    • Current goals:
      • JavaFX-based rich client
      • Remote management of multiple Drombler JStore Client Agents
      • Discover applications on Drombler JStore
      • Rate applications on Drombler JStore
      • Comment on applications on Drombler JStore
      • Register vendors
    • PoC:
      • Drombler FX-based rich client
      • Initial multiple Drombler JStore Client Agent management support
      • Pluggable feature support
      • Connect to the Drombler JStore REST service
    • GitHub:
  • JAP Maven Plugin
    • Current goals:
      • Define a platform-independent application packaging format and metadata
      • Provide Maven tooling
    • PoC
      • Creates a ZIP-based package, which contains the application in a nested ZIP-file.
    • GitHub:
    • In the future, there could be similar solutions to other build tools, such as Gradle

Call to the Community

As mentioned above, if we need a different deployment model, then it will have to be community driven.

What do think about this proposed solution?

Do you have a need for an alternative deployment model?

Do you think we’re running in the right direction with this proposed solution or did we miss something?

Contributions and Donations

Even for an MVP (Minimal Viable Product), there is quite some work to do.

Contributions are extremely welcome! The current code base is not very complex. You should be able to get started quickly. Please don’t hesitate to ask me, if you have any questions.

We can use your inputs especially in the following areas:

  • What should the platform-independent application packaging format and metadata look like to support your applications? What information is needed by the agent? What information is only needed by the discovery feature of the rich client?
  • Help us to make sure the agents have the necessary native OS integration to support your applications.
  • Help us to create a great user experience with the rich client (some UX and JavaFX skills required)
  • Help translate the texts of the rich client to different languages (i18n/ l10n)
  • Help us to get the basic features of the agent right
  • File enhancement requests for the various components
  • Join the discussions in the issues or on Gitter.
  • Help with the documentation (GitHub Pages, README files)

Since the proposed solution requires a backend, this will also require some resources to run the service. Any donations are welcome!

Further Readings

Here are some further blog posts about similar topics:


A lot is going on in the Java world. But these changes also provide opportunities for new solutions.

Join and help to shape the next generation of Java application deployments!

Original Link

How Do We Define Java?

Java is a massively overloaded word. For starters, it is the name of an Indonesian island as well as a term for coffee. Then, we have Java — the computing platform. Even in regards to a computing platform, the word has taken on several meanings: are we talking about Java, the programming language syntaxJava, the virtual machine, or Java, the Development Kit (JDK)? Along with these primary uses, there are many more ways we can use the term Java —cardembeddedMicro Edition and Enterprise Edition (at least now we have the disambiguation of this being Jakarta EE). 

Where am I going with this? Well, as part of some of the work I was doing on a whitepaper for JDK migration, I was compiling an exact list of differences between the Oracle JDK and Zulu JDK, which is a straight build of the source provided by the OpenJDK project. Since I’m also on the Expert Group for the Java SE specification, this got me thinking about how we define what is and isn’t part of Java.

This led me to think about what we actually mean by Java. Around the same time JDK 9 was released last year, Oracle made a number of announcements about how JDK would be developed and delivered in the future. I’ve written about much of this before, but one part of this was the elimination of all functional differences between the Oracle JDK and the one built from OpenJDK source. This work will be complete when JDK 11 is released later this year and involves both the addition of components to the OpenJDK project as well as the removal of features from the Oracle JDK.

Much of this has been well publicized already. What were commercial features such as application class data sharingJava Flight Recorder and Java Mission Controlhave all been contributed as open-source by Oracle to the OpenJDK project. Other features like JavaFX, the browser plugin, and Java Web Start will all be dropped from the Oracle implementation of JDK 11.

The point that I’m trying to get to is how this actually gets defined. It’s useful to put this into a Venn diagram to understand things a little more clearly.

Venn Diagram

The smallest section is Java SE. This is the specification defined by the JSR through the JCP. If you want to create something that can be called Java, then this is the minimum set of requirements for what you need to provide. This includes the standard set of libraries (all the java and javax packages, plus some org.xml and org.w3c ones) as well as a JVM that can process the defined set of bytecodes. The JVM is defined in terms of functionality, like that it requires a garbage collector, but not how it should be implemented.

At the next level, we have the OpenJDK. This is the reference implementation for the Java SE standard, so, naturally, it contains everything in that. It also includes things that are not defined by Java SE.  Things like the JavaScript engine, Nashorn, are part of OpenJDK but not Java SE (the Java SE spec defines an interface to a scripting engine but not the implementation of any such engine). 

Since OpenJDK is a superset of Java SE, the OpenJDK project came up with an alternative way to define new features of the OpenJDK. These are called JDK Enhancement Proposals (JEPs). Although not a formal standards process, this is an open process. Anyone who has committer status for OpenJDK is free to submit a JEP. Of course, since we’re dealing with the core Java platform, used by literally millions of developers, it is not a given that submitting an interesting idea as a JEP will get it accepted (far from it, in fact). To date, only one feature JEP that changes the API has been successfully submitted, accepted and released by someone outside Oracle. That was JEP 285, Spin-wait hints from us here at Azul. This is the addition of a single method to the Thread class that, in many implementations, will do nothing. The amount of effort and review that we needed to go through to get this into OpenJDK was substantial. Again, given the widespread use of Java, this is quite reassuring.

There are a few more non-Oracle JEPs that are for different ports of the JDK (JEP 175and JEP 294 from SAP and JEP 237 from Red Hat) and one that will be included in JDK 11 (the Epsilon garbage collector, JEP 318, from Red Hat). 

Interestingly, the term JEP has more recently become something of a misnomer. Two JEPS, 313 and 320, describe the removal of features. I guess you can enhance something by removing things, but this does seem a little counter-intuitive.

Finally, we have the Oracle JDK. Since this is Oracle’s binary distribution of the OpenJDK, they are free to add whatever features they like to add value. JavaFX is an excellent example of this. JavaFX has its own open source project (OpenJFX), which is separate from OpenJDK. JavaFX was never integrated into the Java SE standard (unlike AWT and Swing). Removal of features like this is entirely at Oracle’s discretion, but they have been reasonably good about publicising things like this through their various blog posts (more of this a little later).

Let’s return to what I said earlier about researching the differences between OpenJDK and the Oracle JDK. As part of this, I did a straight diff on the list of modules in JDK 10 and JDK 11. It turns out 31 modules have been removed and two have been added.

Firstly, there is the removal of the aggregator-module. This references six modules that are part of Java SE so have been removed from the Java SE 11 specification. The aggregator module and two related jdk specific modules are not part of the Java SE specification.  JEP 320 describes the complete changes to the JDK.

  • java.activation
  • java.corba
  • java.transaction
  • java.xml.bind
  • jdk.xml.bind (non-Java SE)
  • (non-Java SE)

The HTTP/2 incubator module introduced in JDK 9 has been removed and replaced with one that is now part of the Java SE standard. This is described in JEP 110JEP 321, and the Java SE 11 specification.

  • jdk.incubator.httpclient replaced with

The modules for JavaFX. As I mentioned, these modules are only included with the Oracle JDK, although JavaFX is part of the wider OpenJDK project. The news of their removal was announced here.

  • javafx.base
  • javafx.controls
  • javafx.deploy
  • javafx.fxml
  • javafx.swing
  • javafx.web

There are two JDK-specific modules for the related Java packager.

  • jdk.packager

The browser plugin and Java Web Start modules. The removal of these features was publicised here.  The modules here are mostly Oracle specific, but there is also the java.jnlp module.

This module had me quite confused.  According to the JDK documentation, all Java SE modules have names that start with java, but it seems not all modules that start with java are in Java SE since java.jnlp is not part of the standard.  It is, however, defined by the JCP as JSR 56.  As such, according to JEP 200, which describes the Modular JDK, the module name starts with java.  The reference implementation of JSR 56 was never released as open source, and so is only part of the Oracle JDK.

  • java.jnlp
  • jdk.javaws
  • jdk.plugin
  • jdk.plugin.server
  • jdk.deploy
  • jdk.deploy.controlpanel

Then, there are miscellaneous modules. There are two that are clearly Oracle specific because it’s included in the name. It seems that because these are desktop and net modules, they have been prefixed with Oracle rather than JDK to prevent confusion.

  • oracle.desktop (Oracle AWT utils)
  • (SDP and NIO Oracle additions)

Finally, we have three other Oracle-specific modules. In these cases, the removal of these features does not appear to have been announced anywhere other than the fact that the documentation for JDK 10 states that they are deprecated.  I’m a bit surprised the removal of SNMP support was not announced somewhere (please correct me if I’m wrong, but a standard search did not reveal anything).

  • (Resource management)
  • (Co-operative memory management)
  • jdk.snmp (SNMP support)

At least from JDK 11, the Venn diagram shrinks to only two circles — OpenJDK and Java SE.

Venn Diagram

I plan to discuss the relationship between the JCP and OpenJDK and how Java features get added or removed in more detail in a later blog post.

Original Link

OpenJDK: A Getting Started Checklist

Hey all! I just got a chance to build the OpenJDK from its source code for a 32-bit Windows machine, so I thought I would share what I learned as well as the steps I used to build it. I hope it might be useful for you.

Why OpenJDK?

So the first thing that comes to our mind is: Why? Open JDK provides you with the freedom to play with the JVM, introducing or modifying the functionality as per your needs. OpenJDK is written in C++ and Java, so you must have a good command of both languages. You can use and distribute the modified version of Java for any purpose, as it falls under the GPL license. Working on OpenJDK also gives you the freedom to suggest or contribute the changes in Java. Obviously, they have a very tough process of review and testing before approval of any change, but here is your chance to be a contributor to the Java language.

How Is It Different From Oracle’s JDK?

Oracle and OpenJDK are built on the same source code. However, both have different licensing policies — OpenJDK is more lenient than Oracle. Meanwhile, the Oracle JDK is an enterprise edition, where you can get some support. Both have a different cycle of release and may differ in some new functionalities.

Who Is Using OpenJDK?

Microsoft and Azul Systems collaborated together and created Zulu to build OpenJDK for users of Windows. IBM is also a user and contributor for OpenJDK and has its own version of Java, called IBM Java, which is based on OpenJDK. Apple also started making some public contributions to the project in 2011.

How to Build It

It took a significant amount of my time to be able to build OpenJDK successfully — it has a lot of dependencies on other software and plug-ins. But I learned a lot while building this, so I am just trying to put my experience in the following simple steps for your quick reference.

  1. Install HG Client to check out the code using the command line. Use the command below to check out the source code.
    hg clone

    jdk8u is their ‘update directory,’ where they push all the latest changes. You can use the last release source or any other previous release, as per your needs.

  2. Run bash ./ from the directory to get the entire OpenJDK repository.
  3. Install make. OpenJDK8 needs make 3.81 or higher version.
  4. Install mingw and mysys. OpenJDK needs a Linux-like environment to be able to run the build commands. You can also use Cygwin instead of mingw mysys.
  5. You also need Visual Studio 2010 professional. You can get it from Microsoft’s official website.
    • ar.exe
    • m4.exe
    • cpio.exe, gawk.exe
    • file.exe
    • zip.exe
    • unzip.exe
    • free.exe.
  6. Below is the list of other packages that you may need to install if they are not already present on your build machine.
  7. The previous version of Oracle’s JDK must be installed on the build machine, which will be used as a boot JDK.
  8. If you are building any Tag version of OpenJDK, then please switch to that before starting the build Process.
  9. The first step of building OpenJDK is to make sure that the system has everything needed to build. For this, you have to run the following command. This will generate error messages if any of the prerequisite software or files are missing. This can be one of the trickiest steps, so be ready for some patient debugging if something goes wrong.
    bash ./configure

  10. Once you are able to configure it successfully, then you have to run the make command to build it, like below.
    make all
  11. When your make command is successful, you can find the OpenJDK and JRE under the “\build\windows-x86-normal-server-release\images” directory in your build directory.


Original Link

Java Annotated Monthly: May 2018

It’s only my (Trisha Gee’s) second month back at the helm of Annotated Monthly, and I’m using the opportunity to link to some of the backlog of articles I amassed while I was away. This month is a bumper edition, including a huge section on culture, as I believe very strongly that developers need to understand so much more than just coding.


As usual, a bit of a mixed bag of tutorials for features from pretty much any version of Java, code examples that help developers to think about the approaches they take to solve problems news that affects Java-the-language specifically.


News that affects Java developers but may not contain code-specific content.

  • Community OpenJDK Build Farm Goes Live, meaning you can now get builds of the OpenJDK without having to go through Oracle
  • Oracle Replaces JavaOne with Oracle Code One – while some are sad that it’s the end of an era, it’s a reflection of the fact that developers now needs to know so about much more than just a single programming language
  • GraalVM 1.0 was officially released, “a universal virtual machine designed for a polyglot world”. Probably not a coincidence then that Oracle wants to expand “Java”One.

Languages, Frameworks, and Libraries

Java EE, Jakarta EE, and Spring all vying for your attention this month.

Software Development

Stuff that’s not specifically Java-code-related, but technical all the same.


This month seemed like the right time to share some of my backlog on company/industry culture given there was quite a lot of noise on Twitter about the importance of diversity and inclusion at (specifically) Java conferences.


May is busy! I’ve picked out the events that might be most interesting to Java / JVM language developers, it includes events where we’ll have a booth, events where one of the team is speaking, and the occasional event with both!

And Finally

News and topics from the IntelliJ IDEA blog and YouTube channel that you may have missed:

Original Link

Recent Java Developments: Late April 2018

There have been several recent developments in the Java-sphere this week and I summarize some of them in this post.

The End of JavaOne as We Know It

In the post “JavaOne Event Expands with More Tracks, Languages and Communities – and New Name,” Stephen Chin writes, “The JavaOne conference is expanding to create a new, bigger event that’s inclusive to more languages, technologies and developer communities.” He adds that it has been renamed to “Oracle Code One” and that this year’s edition (the “inaugural year of Oracle Code One”) will be held in San Francisco’s Moscone West in late October (October 22-25, 2018).

GraalVM: “Run Programs Faster Anywhere”

In the 17 April 2018 post ” Announcing GraalVM: Run Programs Faster Anywhere,” Thomas Wuerthinger and the GraalVM Team “present the first production-ready release” of “a universal virtual machine designed for a polyglot world” called GraalVM 1.0. GraalVM Community Edition (CE) is open source and is hosted on GitHub. The main GraalVM page describes it as “a universal virtual machine for running applications written in JavaScript, Python 3, Ruby, R, JVM-based languages like Java, Scala, Kotlin, and LLVM-based languages such as C and C++.”

JavaScript and the JVM-based languages are recommended for production use of GraalVM 1.0 with improved support advertised for other languages in the near future. The GraalVM Downloads page provides for downloads of either the Community Edition (from GitHub) or the Enterprise Edition (EE, from Oracle Technology Network).

Mission Control Project in OpenJDK

Marcus Hirt has proposed “the creation of the Mission Control Project” on the OpenJDK announce mailing list. This seems like a logical step in the effort discussed in Mark Reinhold‘s message ” Accelerating the JDK release cadence” to “open-source the commercial features in order to make the OpenJDK builds more attractive to developers and to reduce the differences between those builds and the Oracle JDK” with the “ultimate goal” of making “OpenJDK and Oracle JDK builds completely interchangeable.”

Flight Recorder in OpenJDK

Speaking of commercial features of the Oracle JDK being brought into the OpenJDK, JEP 328 (“Flight Recorder”) had some interesting news this month with Markus Gronlund’s hotspot-dev mailing list announcement of the availability of “a preview of a large part of the source code for JEP 328: Flight Recorder.”

JEP 321: HTTP Client (Standard) Targeted for JDK 11

As announced late last month, JEP 321 [“HTTP Client (Standard)”] has been targeted for JDK 11.

Significant Progress on Switch Expressions (and Improving Switch Statements)

There has been significant progress in the OpenJDK mailing lists’ high-level design of switch expressions that includes enhancements to the existing switch statements since my original post on switch expressions. I have summarized some of the latest discussion (particularly that in a Brian Goetz post) in a recent blog post called ” Enhancing Java switch Statement with Introduction of switch Expression.”

Should I Return A Collection or Stream?

There’s an interesting thread ” Should I return a Collection or a Stream?” on the Java subreddit that is based on an interesting July 2017 discussion on StackOverflow related to whether it’s most appropriate to return a Collection or a Stream in a particular case.

Original Link

Java-Related April Fools Day Pranks

Although you’d never catch me stooping to this level, it has been interesting over the years to see some of the effort and thought put into Java-related April Fools’ Day pranks. This post references and summarizes some of them.

Google Annotations Gallery (gag)

The Google Annotations Gallery (cleverly abbreviated as ‘gag’) is hosted on Google Code, so you may want to download that as soon as possible so that you do not miss out on it. Both (original release) and (supplements original release to “add many great user-suggested annotations”). These ZIP files include actual Java source code with the libraries that gag depends on.

Some of my favorite annotations provided by gag are @AhaMoment, @Blame, @BossMadeMeDoIt, @Facepalm, @Hack, @HandsOff, @IAmAwesome, @LegacySucks, @Magic, @Noop, and @OhNoYouDidnt.

I also enjoy the WHERE enumeration provided by ‘gag’ to allow one to specify “where” a particular annotation’s meaning may have occurred. Values for WHERE cover the most likely locations to think up the best ideas (most “free time”): BATH, BED, BORING_MEETING, DMV, GYM_WORKOUT, SHOWER, TOILET, and TRAFFIC_JAM.

I was negligent in not mentioning the ‘gag’ library in my recent post on how to effectively divert blame.

New OpenJDK Project: Even Faster JDK Releases

This year (2018), the discuss OpenJDK mailing list includes a couple threads with April Fools’ Day hoaxes. One of these, “New project proposal: even faster JDK releases,” is particularly timely given the relatively recent change to a new Java release every six months. The new cadence has caused some concerns such as those described in “The Java release train is moving faster, but will developers be derailed?

The April 1 proposal proposes “the creation of project Doomed, which aims to solve an extremely important issue caused by the currently specified fast release schedule, that of an equally fast adoption.” Before making several other arguments for Project Doomed, the proposal states, “With project Doomed we aim at continuous release and deployment of the JDK, thus removing the need to have any version number and increase the adoption rate considerably and better position the JDK in the fast pacing world of cloud development.”

New OpenJDK Project: The Block GC

Another April 1 thread on the discuss OpenJDK mailing list starts with the post “New Project Proposal: The Block GC.” The proposal here is for “Block Chain GC”, “an innovative new system for Garbage Collection.” Among other advertised virtues of the Block Chain garbage collector is the ability for it to be “used to calculate hash values for popular cryptocurrencies, a.k.a. ‘bitcoin mining'”. The proposal also outlines where the default recipients of the revenues generated from the Block Chain garbage collector: “by default, the revenue extracted by the Block GC miner will be stored in the Block GC Project account. This revenue will be divided as follows: 90% will go to the initial committers of the Block GC Project, and 10% will go to the OpenJDK community.”

Apache Software Foundation Sold to Oracle

The 2010 April Fools post “The Apache Software Foundation Receives Approval for Sale to Oracle Corporation” announced “Today, the Apache Software Foundation announced it has agreed to sell all IP and assets of the foundation to Oracle.”


ZeroTurnaround announced Frostbyte on April Fools Day in 2012 and advertised it as “a new stack-based language for the JVM” that was “born out of frustration of working with the standard Java software stack and tools.” Among Frostbyte’s advertised features were “use of inverse reverse Polish notation with parentheses” and “the built-in default language is Estonian.” Perhaps the most promising feature of Frostbyte was “built-in AI that is able to make aesthetic judgments about your code and will outright disallow ugly code, over-abstractions, and excessive copy-and-pasting.”

Goto in Java

Another 2010 April Fools Day announcement was Joe Darcy’s “Goto for the Java Programming Language.” “Endorsed” by “Edsger Dijkstra” (author of “go to statement considered harmful“), this proposal advertises that it will “Provide the benefits of the time-testing goto control structure to Java programs.” Fortunately, Java still doesn’t have that form of a “goto,” but it does have its own narrowly-scoped similar capability.

Neo 4 Java

On April Fools’ Day 2016, the Neo4j blog announced Neo 4 Java, “a proprietary 100% pure Arabica available in the caffeine aisle soon, or possibly right at your desk if you happen to have a 3D printer or a really good intern.”

Minecraft Java Edition Textures Finally Perfected

In “Java Edition Textures Finally Perfected,” it was announced of April Fools Day this year that “a new default texture pack for the Java Edition of Minecraft” was being released. Not everyone thought this was funny because it apparently cost some Minecraft users quite a bit of time before they realized it was a one-day prank. A Minecraft bug, MC-127786, was reported with this moderator response, “April fools! This is an April Fools’ joke by Mojang. Textures will return back to normal once April Fools’ Day is over.” Minecraft users should probably be especially wary of April Fools Day pranks because it’s not the first time that Mojang has pulled one.


Several of the April Fools’ Day posts described above required a surprising amount of ingenuity, effort, and time.

Original Link

JavaOne 2017 Day 1 Keynote: Notes and Thoughts

Unfortunately, I wasn’t lucky enough to attend JavaOne 2017 this year, so I’m catching up this evening and watching the recording of the Day 1 Keynote here.

A few notes, key quotes, and thoughts (screenshots taken from the video):

Mark Cavage, Vice President of software development, Oracle:

  • The next decade: Java first, open, evolving, nimble, scalable
  • Java EE 8. “Is it nimble? Well no, EE7 shipped 4 years ago”
  • Java EE moving to the Eclipse Foundation. What does this mean? It means everything is moving to the Eclipse Foundation
  • David Blevins (Tomitribe), Ian Robinson (IBM) and Mark Little (Red Hat) take the stage to talk about moving EE to the Eclipse Foundation:
    Java 9:
    • From this point onwards, all features in Oracle JDK and OpenJDK will be the same, zero difference between them
    • Releases of Java will now be every 6 months.

    James Governor, RedMonk:

    • “Things have changed more in the Java ecosystem in the last 3 weeks than they have in the previous 13 years.”
    • Observations about the adoption of Java by web companies, most of which rejected Java initially in favor of Ruby and other cooler technologies, only to adopt Java later as they struggled to adapt and scale.

    Cloud, Niklas Gustavsson, Spotify:

    Java and Kubernetes Craig McLuckie, Heptio:
    Wercker, Java, and Kubernetes:

    • Build, deploy and operations support for Container based apps

    Observability and Operations:

    • Java Flight Recorder: now open sourced
    • Container Native development, simpler
    • With microservices, you need to know not just when an issue occurred, but where? (which service, and where is it running)
    • Container Diagnostics Service: runs in production, low overhead

    Serverless: The Fn Project

    Eugene Petrenko, Jetbrains:

    (As a sidenote, is the first JavaOne keynote where the new tech demo was done with an IDE other than Netbeans? Unless I missed it, there was no mention of Netbeans in the keynote this year).

    Mark Reinhold:

    • New feature releases every 6 months
    • New features will be included only when they are ready (if they don’t make the next 6 month release then they’ll get moved to the next)
    • The next release is only 5 months away!

    Brian Goetz: Project Amber: Right-sizing Language Ceremony

    That’s a lot of changes and content, time to go check out those new features!

Original Link