Java 9 Released: What’s in Stock?

SFL
SFL Newsroom

--

Good news is finally here: Java 9 has been officially released!The Java 9 Standard Edition had previously been delayed several times, extending to a period of 1 year, because of modularity controversy. Given that JDK 9 is the first major upgrade to standard Java edition in over three years (the last update took place in March 2014), the Java community was in anticipation of some major changes coming their way. Let’s have a look at what exactly this change brought along:

Changes in modularity: Project Jigsaw

This is the change that was taking so long to refine. Project Jigsaw is an all-new module system which will bring modularity to JDK, run-time images, Java source code, etc. It’s intended for code simplification, since developers can create their own modules.

Project Kulla or jshell

Java 9 features a new command line tool called jshell which will add native support and popularize a Java way to REPL (Read-Eval-Print-Loop).

So, if you decide to run a couple of lines of Java Code in Java 9, you won’t have to wrap them up in a separate method or project. Also, you can now forget about semicolons!

Parser API for Nashorn

Another new feature in Java 9 is a parser API for better project Nashorn JS support. Its main goal is to implement a lightweight high-performance JS runtime in Java with a native JVM.

Process API Changes

With Process API improvements, Java 9 ensures that OS process are controlled and managed in a better manner.

Stream API enhancements

The Streams API is arguably one of the most notable changes to the JSL recently. Java 9 introduces several new methods to the Stream interface: dropWhile, takeWhile, ofNullable. The iterate method gets a new overload, which allows to provide a Predicate on when to stop iterating

Segmented Code Cache

JDK 9 introduced Segmented Code Cache, allowing for the division of code cache into segments based on type. This feature is very useful in terms of providing better performance.

New HTTP 2 Client

In order to improve performance, reduce page loading times and resource usage, Java 9 features a new HTTP2 client API for implementing HTTP/2 and WebSocket.

This list isn’t exhaustive. There are many more interesting features that you can know more about from Java 9 release notes. Alongside reading, you can already download Java 9 and get to play with it on your own.

About this author:

Armine Hakobyan is a content writer with a heart for technology and innovation.

Let’s talk!

--

--