What’s New in Java 11

What’s New in Java 11

Duration: 3 Days

Description

This course focuses on the features and enhancements introduced in Java 11, a long-term support (LTS) release that brought meaningful improvements to the language and standard library. Participants explore new String methods, local-variable syntax for lambda parameters, the HTTP Client API, updates to the Stream and Optional APIs, and changes to the Java platform module system. The course also covers key JDK changes, including the removal of Java EE modules and new tooling for running single-file source programs.

Audience

This course is intended for Java developers proficient with Java 8 who want to understand the language’s evolution through Java 11. It’s ideal for teams planning a migration to Java 11 LTS and developers maintaining modern Java applications who want to stay current with platform changes.

Objectives

  • Utilize new String methods for improved text processing and manipulation
  • Apply var in lambda parameters for cleaner functional code
  • Make HTTP requests using the new standard HTTP Client API
  • Leverage enhancements to the Stream, Optional, and Collection APIs
  • Understand the Java Platform Module System changes and implications
  • Run single-file Java programs without explicit compilation
  • Recognize removed and deprecated APIs and plan migration strategies
  • Apply performance improvements and garbage collector updates

Prerequisites

Participants must have strong Java 8 knowledge, including lambda expressions, streams, functional interfaces, and the modern Date and Time API. Professional Java development experience is expected. Familiarity with Java 9 and 10 features is beneficial but not required.

Course Outline

Module 1: Overview of Java 11

  • Java 11 as a Long-Term Support Release
  • Release Cadence and Versioning Changes
  • Key Themes in Java 9-11
  • Removed and Deprecated Features

Module 2: Language Enhancements

  • Local-Variable Syntax for Lambda Parameters
  • Lambda Expression Improvements

Module 3: New String Methods

  • isBlank, lines, strip, and stripLeading/stripTrailing
  • repeat Method
  • String Processing Enhancements

Module 4: HTTP Client API

  • Overview of the HTTP Client
  • Creating HTTP Clients and Requests
  • Synchronous and Asynchronous Request Handling
  • Working with HTTP Responses
  • WebSocket Support

Module 5: Collection and Stream API Updates

  • Collection.toArray(IntFunction)
  • Predicate.not Method
  • Stream and Optional Enhancements

Module 6: File I/O Enhancements

  • Reading and Writing Strings to Files
  • Path and Files API Updates

Module 7: Running Java Programs

  • Single-File Source Code Execution
  • Shebang Support for Java Scripts

Module 8: JVM and Platform Changes

  • Epsilon and ZGC Garbage Collectors
  • Flight Recorder
  • Module System Updates
  • Removed Java EE and CORBA Modules
  • Migration Considerations