Java 9 – The Ninth Step for Java, Moving to a New Age Altogether

Page 1

Java 9 – The Ninth Step for Java, Moving to a New Age Altogether ` Java 9, known as the Java Platform Standard Edition version 9 earlier arrives and so does the Java Development Kit (JDK) for the developers to download, promising enough to inspire all to revamp the java application development services on offer. This Christmas, a Toast for Java. Cheers to that! Java 9 turned into a long-term project, beginning almost from the time Oracle first started mentoring this language soon after it took over the Sun Microsystems way back in early 2010. The very first task for Oracle, soon after the acquisition and the initial hiccups stabilized was to take stock of the situation within the code and that is when came the big decision to modularize the language.


The Top-Class Features with Java 9 for Custom Java Development Java Standard Edition version 9 has been a major feature release for Java platform with various architectural and component level changes with notable features to the kitty. Strong & Refreshing – Java the Cup of Good Taste Modular Approached System (Jigsaw Project) Though Module system has been the key feature of Java 9 it is still quite controversial. It is released as a part of Oracle’s Jigsaw Project to eliminate the weakness of the previous versions of Java. This latest version of Java comes with segmented modules like the JDK, JRE, JAR and more for the developers to implement in accordance with the demand of the application. Modularity also called a transitive change, enables understanding dependencies among modules. Module system has the advantage of ease of testing and maintenance, better performance, strong encapsulation, less coupling of components and restricts access to internal non-important API’s. It also helps to scale down to the smaller device along with improving security and performance. The modularity approach of Java 9 has application packaging, which makes smaller parts of the JDK and reorganizes the source code into modules. The build system also compiles modules and maintains the module segmentation during build time. JDK and JRE are enhanced to handle modules. Also, the JavaFX UI and CSS API are a part of the module system approach. Despite the agreement among the majority of Java enthusiasts, there is a raging debate whether modularity will really do some good to the Java developers. Java 9 will at least for the time being allowed illegal reflective access to the code on the classpath that is used by JRE so as to search classes and resource files. This option will be disallowed post-Java 9 Improvements in the Compiler for Java 9 code

The compiler for Java 9 has several enhancements but important among them is the Ahead-of-Time (AOT) Compilation. Though it is still in its initial days, this compiles the Java classes to native code before


it is launched into the virtual machine. This improves the startup time for both small and large applications. Just-in-time (JIT) compilation though is fast but has performance related issues when it comes to large sized application leaving some methods without compilation. AOT helps to address these issues. Java-level JVM Compiler Interface (JVMCI) is another experimental feature added to the compiler. This interface allows the compiler to be used as the dynamic compiler by JVM. The API has the mechanism to access VM structures, install compiled the code and plug into JVM compilation system. Writing a JVM is a compiler in java allows a higher quality compiler that is easy to maintain and improve than the compiler that was written in C or C++. Compiler written in Java becomes easy to maintain and improve for Java application development services REPL in Java 9 After several years of efforts under the project Kulia, the read-eval-print loop (REPL) tool, which was a long-term goal for Java, is now added in Java 9. Java’s REPL called jShell evaluates statements and expressions. Developers get feedback about the program before compilation by entering certain commands. The command-line tool’s capabilities involve tab completion and automatic addition of the terminal semi-colon wherever needed. jShell API allows jShell functionality in the IDE and other tools. Streams API in Java 9 Stream in Java enables developers to express the calculation related expression in a way that allows data parallelism. The Stream in Java 8 helped in processing data declaratively. The Stream API adds methods that take and drop item conditionally from the Stream and iterate over the Stream elements creating a Stream from nullable value along with expanding the Java SE API that also serve as Streams sources. Code cache can be divided in Java 9 In Java 9, the code cache can be divided thus improving the performance and allowing extension like fine-grained locking. This results in improved sweep times due to specialized iterators eliminating nonmethod code, profiled and non-profiled code and thus improving the execution time and giving a push to custom Java development in a big way. Better JavaScript backing in Java 9 A lightweight runtime Javascript is being improvised in JDK9 under the Project Nashorn. This project aimed to implement efficient yet lightweight runtime Javascript taking it up from the Rhino project that was started at Netscape. Project Nashorn was charged with enabling embedded Javascript in the Java projects. It has provided Java that had a Javascript engine in JDK 8.


JDK 9 also has a parser API for the ECMA script syntax tree. This API enables ECMA Script code analysis by IDEs and server-side frameworks without depending on the internal implementation classes of Project Nashorn. HTTP/2 client API The beta version of HTTP/2 is a part of JDK 9 which implements the upgrades in java to the web’s core HTTP protocol. WebSocket is also supported by the API. HTTP/2 API can substitute the HttpURLConnection API, which had several issues if being designed with low-defunct protocols anteceding the HTTP/1 which is too abstract and difficult to use. Improved HTML5 and Unicode support in Java 9 The JavaDoc tool has been enhanced to create HTML5 mark up. The Unicode 8.0 encoding standard is also well supported providing 8,000 characters, 10 blocks and 6 scripts. DTLS security API in Java 9 From a security perspective, the DTLS (Datagram Transport Layer Security) API has added into JDK 9. This protocol prevents message forgery, eavesdropping and tampering with the client-server interaction. This implementation has both client and server modes. To Make a Long Story Short Java 9 release with all its new features arrives with a bang. Oracle also revealed that Java 9 is last of its kind release in terms of the time gap between the major releases and its designation. Java @ 20+ Maintains Its Supremacy in the Enterprise World Java is now planned to have a 6-month release calendar the next major release being called Java 18.3 which due on March 18 followed by the next release Java 18.9 which will be 6 months later creating a lot of enthusiasm in enterprises offering Java application development services. The proposed roadmap leading to Java 9, shared way back has more or less been adhered to and here we are today with Java 9.


Know How We Can Add-on To Your Java Ecosystem


Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.