Packt
Modern Java - Mastering Features from Java 8 to Java 21
Packt

Modern Java - Mastering Features from Java 8 to Java 21

Included with Coursera Plus

Gain insight into a topic and learn the fundamentals.
Intermediate level

Recommended experience

28 hours to complete
3 weeks at 9 hours a week
Flexible schedule
Learn at your own pace
Gain insight into a topic and learn the fundamentals.
Intermediate level

Recommended experience

28 hours to complete
3 weeks at 9 hours a week
Flexible schedule
Learn at your own pace

What you'll learn

  • Implement lambda expressions and functional interfaces to write concise, functional Java code.

  • Utilize the Streams API for efficient, declarative data processing and parallelism.

  • Master new Java features like records, sealed classes, pattern matching, and the modern HTTP client.

  • Build modular Java applications using the Java Platform Module System (JPMS) for scalable architecture.

Details to know

Shareable certificate

Add to your LinkedIn profile

Recently updated!

July 2025

Assessments

29 assignments

Taught in English

See how employees at top companies are mastering in-demand skills

 logos of Petrobras, TATA, Danone, Capgemini, P&G and L'Oreal

There are 28 modules in this course

In this module, we will introduce you to the course framework and outline the key Java features from Java 8 to Java 21 that you will master. You will also review the pre-requisites, ensuring you have the necessary foundation and tools to succeed. This section sets the stage for an efficient and productive learning experience.

What's included

2 videos1 reading

In this module, we will explore the big picture of modern Java, tracing its evolution from Java 8 to Java 21. You will gain insight into why these features matter and how they impact programming practices today. This foundational overview prepares you for deeper dives in subsequent modules.

What's included

1 video1 assignment1 plugin

In this module, we will guide you through installing Java and setting up your development environment. By the end, you'll be ready to write and run Java programs locally. This hands-on setup ensures you can follow along with the practical labs throughout the course.

What's included

1 video1 assignment1 plugin

In this module, we will uncover why Java 8 is a landmark release that revolutionized Java development. You will contrast imperative and declarative programming styles with practical examples, building a solid understanding of the shift that modern Java embraces.

What's included

3 videos1 assignment1 plugin

In this module, we will introduce lambda expressions and their importance in writing concise Java code. You will get hands-on experience implementing common interfaces like Runnable and Comparator with lambdas, enhancing your functional programming skills.

What's included

3 videos1 assignment1 plugin

In this module, we will explore the core functional interfaces integral to Java’s lambda expressions. Through progressive labs, you will practice using Consumer, Predicate, Function, and other interfaces to write clean, functional-style Java code.

What's included

13 videos1 assignment1 plugin

In this module, we will deepen your understanding of concise coding by exploring method references. You will practice transforming lambda expressions into method and constructor references to write clearer, more readable Java programs.

What's included

5 videos1 assignment1 plugin

In this module, we will examine how local variables behave inside lambda expressions. You will learn about the importance of effectively final variables and their benefits, enabling you to avoid common pitfalls when writing lambda-based code.

What's included

2 videos1 assignment1 plugin

In this module, we will introduce the Streams API as a powerful tool for functional-style data processing. You will understand how streams work behind the scenes and explore their advantages over conventional collection handling.

What's included

4 videos1 assignment1 plugin

In this module, we will engage with a wide range of stream operations through practical labs. You will transform, filter, sort, and reduce data streams, mastering the key techniques to leverage streams for efficient data manipulation.

What's included

15 videos1 assignment1 plugin

In this module, we will focus on stream creation using factory methods. You will learn how to generate streams from various sources and patterns, equipping you to start stream-based processing in diverse contexts.

What's included

1 video1 assignment1 plugin

In this module, we will explore numeric streams designed for efficient processing of primitive data types. You will perform common statistical calculations and transform between different stream types to optimize performance.

What's included

5 videos1 assignment1 plugin

In this module, we will delve into terminal operations that conclude stream pipelines. You will learn how to collect, group, partition, and summarize data effectively using the Streams API's rich set of collector utilities.

What's included

10 videos1 assignment1 plugin

In this module, we will introduce parallel streams as a means to leverage multi-core processors. You will build parallel pipelines, analyze their behavior, and understand when to use or avoid parallelization for optimal results.

What's included

6 videos1 assignment1 plugin

In this module, we will introduce the Optional class as a robust alternative to null handling. You will learn how to create Optionals, safely retrieve values, and transform them with functional operations to write safer, cleaner code.

What's included

6 videos1 assignment1 plugin

In this module, we will explore the enhanced capabilities of interfaces with default and static methods. Through practical labs, you will implement these methods, handle multiple inheritance scenarios, and understand their impact on interface design.

What's included

8 videos1 assignment1 plugin

In this module, we will cover the comprehensive Java 8 Date/Time API. You will practice working with various date and time classes, formatting/parsing, timezone conversions, and calculating differences, modernizing your time-based programming skills.

What's included

16 videos1 assignment1 plugin

In this module, we will guide you through establishing a foundational project setup. This will enable you to experiment seamlessly with Java 9 and later features in a well-organized environment.

What's included

1 video1 assignment1 plugin

In this module, we will introduce the ‘var’ keyword for local variable type inference. You will learn how to leverage it for concise declarations while understanding best practices and limitations to write clear, maintainable code.

What's included

2 videos1 assignment1 plugin

In this module, we will explore Text Blocks, a feature that streamlines multiline string management in Java. You will practice creating and formatting text blocks for cleaner and more readable string code.

What's included

1 video1 assignment1 plugin

In this module, we will uncover the power of enhanced switch expressions. You will learn to write concise, readable switch statements with expression forms, yield usage, and exhaustiveness checks for safer code.

What's included

3 videos1 assignment1 plugin

In this module, we will introduce record classes as a succinct way to model immutable data. You will enhance records with custom logic and explore how Java automatically generates common methods for convenience.

What's included

3 videos1 assignment1 plugin

In this module, we will explore sealed classes and interfaces, allowing fine-grained control over class hierarchies. You will practice defining and managing inheritance boundaries for more secure and maintainable designs.

What's included

4 videos1 assignment1 plugin

In this module, we will cover pattern matching techniques to simplify type checks and data deconstruction. You will practice with record and guarded patterns to write expressive and maintainable conditional code.

What's included

3 videos1 assignment1 plugin

In this module, we will dive into a real-time CheckoutService application. You will explore its architecture and build key features using sealed classes, consolidating your understanding of advanced Java concepts in a practical context.

What's included

2 videos1 assignment1 plugin

In this module, we will create a simple web server leveraging the new capabilities introduced in Java 18. You will get hands-on experience with lightweight HTTP handling and server setup for web-based applications.

What's included

1 video1 assignment1 plugin

In this module, we will explore the new HttpClient API for performing HTTP requests in Java. You will implement synchronous and asynchronous calls, perform testing, and handle real-world data retrieval scenarios.

What's included

4 videos1 assignment1 plugin

In this module, we will introduce the Java Platform Module System to help you create modular, maintainable applications. You will set up modular projects, handle complex dependencies, and migrate legacy codebases efficiently.

What's included

5 videos3 assignments

Earn a career certificate

Add this credential to your LinkedIn profile, resume, or CV. Share it on social media and in your performance review.

Instructor

Packt - Course Instructors
Packt
756 Courses157,214 learners

Offered by

Packt

Why people choose Coursera for their career

Felipe M.
Learner since 2018
"To be able to take courses at my own pace and rhythm has been an amazing experience. I can learn whenever it fits my schedule and mood."
Jennifer J.
Learner since 2020
"I directly applied the concepts and skills I learned from my courses to an exciting new project at work."
Larry W.
Learner since 2021
"When I need courses on topics that my university doesn't offer, Coursera is one of the best places to go."
Chaitanya A.
"Learning isn't just about being better at your job: it's so much more than that. Coursera allows me to learn without limits."
Coursera Plus

Open new doors with Coursera Plus

Unlimited access to 10,000+ world-class courses, hands-on projects, and job-ready certificate programs - all included in your subscription

Advance your career with an online degree

Earn a degree from world-class universities - 100% online

Join over 3,400 global companies that choose Coursera for Business

Upskill your employees to excel in the digital economy

Frequently asked questions