Book Image

Java 9: Building Robust Modular Applications

By : Dr. Edward Lavieri, Peter Verhas, Jason Lee
Book Image

Java 9: Building Robust Modular Applications

By: Dr. Edward Lavieri, Peter Verhas, Jason Lee

Overview of this book

Java 9 and its new features add to the richness of the language; Java is one of the languages most used by developers to build robust software applications. Java 9 comes with a special emphasis on modularity with its integration with Jigsaw. This course is your one-stop guide to mastering the language. You'll be provided with an overview and explanation of the new features introduced in Java 9 and the importance of the new APIs and enhancements. Some new features of Java 9 are ground-breaking; if you are an experienced programmer, you will be able to make your enterprise applications leaner by learning these new features. You'll be provided with practical guidance in applying your newly acquired knowledge of Java 9 and further information on future developments of the Java platform. This course will improve your productivity, making your applications faster. Next, you'll go on to implement everything you've learned by building 10 cool projects. You will learn to build an email filter that separates spam messages from all your inboxes, a social media aggregator app that will help you efficiently track various feeds, and a microservice for a client/server note application, to name just a few. By the end of this course, you will be well acquainted with Java 9 features and able to build your own applications and projects. This Learning Path contains the best content from the following two recently published Packt products: • Mastering Java 9 • Java 9 Programming Blueprints
Table of Contents (33 chapters)
Title Page - Courses
Packt Upsell - Courses
Preface
25
Taking Notes with Monumentum
Bibliography
Index

Java 9 at 20,000 feet


You might be asking yourself--isn't Java 9 just a maintenance release with a set of features that did not make it into Java 8? There is plenty of new stuff in Java 9 that makes it a distinct version in its own right.

Inarguably, the modularization of the Java platform (developed as part of project Jigsaw) is the biggest piece of work that makes it successfully in Java 9. Initially planned for Java 8, but postponed, project Jigsaw is also one of the main reasons why the final release of Java 9 was further postponed. Jigsaw also introduces a few notable changes to the Java platform and is one of the reasons Java 9 is considered a major release. We will explore these features in detail in the subsequent chapters.

The JCP (Java Community Process) provides the mechanisms to turn a set of feature proposals (also known as Java Enhancement Proposals or JEPs) into formal specifications that provide the basis to extend the platform with new functionality. Java 9 is no different in that regard. Apart from the Jigsaw-related Java enhancement proposals, there is a long list of other enhancements that made it in Java 9. Throughout this book, we will discuss the various features in terms of logical groups based on the corresponding enhancement proposals, including the following:

  • The Java Shell (also called JShell)--an interactive shell for the Java platform
  • New APIs to work with operating system processes in a portable manner
  • The Garbage-first (G1) garbage collector introduced in Java 7 is made the default garbage collector in Java 9
  • Adding the Java Microbenchmark Harness (JMH) tool that can be used to run performance benchmarks against Java applications is included as part of the Java distribution
  • Support for the HTTP 2.0 and WebSocket standards by means of a new client API
  • Concurrency enhancements among which is the definition of the Flow class, which describes an interface for the reactive streams specification in the Java platform

Some of the initial proposals that were accepted for release 9 did not make it there and were postponed for a later release, along with other interesting things that developers may expect in the future.

You can download the JDK 9 distribution for your system from http://www.oracle.com/technetwork/java/javase/downloads/index.html, if you are eager to get your hands dirty before trying to move through the other chapters and experimenting with the newly introduced samples and concepts.