Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Mastering Java 11

You're reading from   Mastering Java 11 Develop modular and secure Java applications using concurrency and advanced JDK libraries

Arrow left icon
Product type Paperback
Published in Sep 2018
Publisher Packt
ISBN-13 9781789137613
Length 462 pages
Edition 2nd Edition
Languages
Tools
Arrow right icon
Authors (2):
Arrow left icon
Dr. Edward Lavieri Jr. Dr. Edward Lavieri Jr.
Author Profile Icon Dr. Edward Lavieri Jr.
Dr. Edward Lavieri Jr.
Mandar Jog Mandar Jog
Author Profile Icon Mandar Jog
Mandar Jog
Arrow right icon
View More author details
Toc

Table of Contents (20) Chapters Close

Preface 1. The Java 11 Landscape FREE CHAPTER 2. Discovering Java 11 3. Java 11 Fundamentals 4. Building Modular Applications with Java 11 5. Migrating Applications to Java 11 6. Experimenting with the Java Shell 7. Leveraging the Default G1 Garbage Collector 8. Microbenchmarking Applications with JMH 9. Making Use of the Process API 10. Fine-Grained Stack Tracing 11. New Tools and Tool Enhancements 12. Concurrency Enhancements 13. Security Enhancements 14. Command-Line Flags 15. Additional Enhancements to the Java Platform 16. Future Directions 17. Contributing to the Java Platform 18. Assessment 19. Other Books You May Enjoy

What this book covers

Chapter 1, The Java 11 Landscape, explores the newly implemented time-based versioning system for the Java platform. We survey the current Java landscape with a specific focus on changes introduced with Java 9, 10 (18.3), and 11 (18.9). Our exploration includes an overview of Java 9's modularity, Java Shell, external process control, garbage collection, JHM, and more. For Java 10, we will highlight key changes to include local variable type inference, JDK consolidation, garbage collection, application class-data sharing, and root certificates, to name a few. Finally, we will explore changes introduced in Java 11, including dynamic class-file constants, garbage collection, and local variable type inference for lambdas.

Chapter 2, Discovering Java 11, looks at several internal changes introduced in the Java platform, including changes from Java 9, 10, and 11. Java 9 represented a major release to the Java platform; Java 10 and 11 were timed releases. Collectively, these releases consisted of a large number of internal changes, representing a tremendous set of new possibilities for Java developers, some stemming from developer requests, others from Oracle-inspired enhancements.

Chapter 3, Java 11 Fundamentals, covers changes to the Java platform that impact variable handlers, import statements, improvements to Project Coin, local variable type inference, root certificates, dynamic class-file constants, and more. These represent changes to the Java language itself.

Chapter 4, Building Modular Applications with Java 11, examines the structure of a Java module as specified by Project Jigsaw. We take a deep dive into how Project Jigsaw is implemented as part of the Java platform. We also review key internal changes to the Java platform as they relate to the modular system.

Chapter 5, Migrating Applications to Java 11, explores how to migrate our existing applications to the current Java platform. We look at both manual and semi-automated migration processes. This chapter aims to provide you with insights and processes to get your non-modular Java code working with the current Java platform.

Chapter 6, Experimenting with the Java Shell, takes a look at the new command line, the Read-Eval-Print-Loop (also referred to as REPL) tool in Java, and the Java Shell (JShell). We start with introductory information regarding the tool, the REPL concept, and move into the commands and command-line options for use with JShell. We take a practitioner's approach to our review of JShell and include examples you can try on your own.

Chapter 7, Leveraging the Default G1 Garbage Collector, takes an in-depth look at garbage collection and how it is handled in Java. We start with an overview of garbage collection and then look at specifics in the pre-Java 9 realm. Armed with that foundational information, we look at specific garbage collection changes in the Java 9 platform. Lastly, we look at some garbage collection issues that persist, even after Java 11.

Chapter 8, Microbenchmarking Applications with JMH, looks at how to write performance tests using the Java Microbenchmark Harness (JMH), a Java harness library for writing benchmarks for the Java Virtual Machine (JVM). We use Maven along with JMH to help illustrate the power of microbenchmarking with the new Java platform.

Chapter 9, Making Use of the Process API, focuses on the updates to the Process class and the java.lang.ProcessHandle API. In earlier versions of Java, prior to Java 9, managing processes in Java was difficult. The API was insufficient with some features lacking and some tasks needed to be solved in a system-specific manner. For example, in Java 8, giving a process access to its own process identifier (PID) was an unnecessarily difficult task.

Chapter 10, Fine-Grained Stack Tracing, focuses on Java's StackWalker API. The API supports special functionality that is rarely needed by ordinary programs. The API can be useful for some very special cases, such as with functionality that is delivered by a framework. So, if you want an efficient means of stack walking that gives you filterable access to stack trace information, you will enjoy using the StackWalker API. The API provides fast and optimized access to the call stack, implementing lazy access to the individual frames.

Chapter 11, New Tools and Tool Enhancements, covers over a dozen tools and tool enhancements relevant to the modern Java platform. The featured changes will cover a wide range of tools and updates to APIs that are aimed at making developing with Java easier and enhance the ability to create optimized Java applications.

Chapter 12, Concurrency Enhancements, covers concurrency enhancements to the Java platform. Our primary focus is the support for reactive programming, a concurrency enhancement that is provided by the Flow class API. Reactive programming was first released in Java 9 and remains an important feature of Java 10 and 11. We also explore additional concurrency enhancements.

Chapter 13, Security Enhancements, looks at several recent changes made to the JDK that involve security. The size of these changes does not reflect their significance. The security enhancements to the modern Java platform provide developers with a greater ability to write and maintain applications that are more secure than previously possible.

Chapter 14, Command-Line Flags, explores several changes to the modern Java platform with the common theme of command-line flags. These include the following concepts: unified JVM logging, compiler control, diagnostic commands, the heap profiling agent, removing your JHAT, command-line flag argument validation, compiling for older platform versions, and the experimental Java-based JIT compiler.

Chapter 15, Additional Enhancements to the Java Platform, focuses on best practices with additional utilities provided with the Java platform. Specifically, this chapter covers support for UTF-8, Unicode support, Linux/AArch64 port, multi-resolution images, and the Common Locale Data Repository.

Chapter 16, Future Directions, provides an overview of the future development of the Java platform beyond Java 11. We look at what is planned for Java 19.3 and 19.9 and what further changes we are likely to see in the future. We start with a brief overview of the JDK Enhancement Program (JEP).

Chapter 17, Contributing to the Java Platform, discusses the Java community and ways developers can contribute to the Java platform. Specifically, the chapter covers the following Java community-related topics, such as the Java community, participating in a Java user group, the Java community process, Oracle Technology Network (OTN), and writing technical articles.

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image