java

Functional Java: Lambda & Streams

Replace loops with Lambdas and Streams for readable, crash-safe, and efficient data processing in modern Java.

Expected Outcome

Ability to write declarative code, build elegant data streams, and handle edge cases in a type-safe manner.

Target Audience

For developers wanting to write cleaner and more readable code using modern declarative patterns.

Prerequisites

Java experience is required, for beginners 'Java Jumpstart: Essentials' is recommended first.

Curriculum & Highlights

Lambdas & Method References
Functional Interfaces
Streams API (Filter, Map)
Data Grouping (Collectors)
Debugging with Peek
Type Safety with Optional
Parallel Streams (N*Q Rule)

Challenges we address

"How do you shift from imperative code to a declarative mindset using Lambdas?"

"How do we dynamically group and aggregate large datasets with Streams and Collectors?"

"When is a Parallel Stream actually faster, and how do you use Optional correctly?"

Detailed Description
Traditional Java code is often filled with anonymous inner classes, extensive for-loops, and complex if-else structures that obscure actual business logic. Without a declarative mindset, data transformations become unnecessarily heavy to maintain, and unhandled searches often result in unwanted NullPointerExceptions as systems scale in production. This workshop introduces a modern way of programming through our Active Learning methodology. We cover how to eliminate boilerplate with Lambdas and Method References, and then build elegant data streams using The Streams API. The result is concise, readable pipelines that focus on what the code should achieve, eliminate null risks via Optional, and prepare the application for performance optimization through multi-threaded execution. We start by demystifying the underlying functional interfaces (such as Predicate and Consumer) to truly understand how Java maps behaviors to types. With this foundation, we build immutable data pipelines where filter and map replace mutable state. For more complex structures, we dive deep into the Collectors utility to dynamically group, join, and partition data. We also discuss the architecture of functional code and how to efficiently debug encapsulated chains using the peek method. In the final section, we focus on stability and extreme scale. We learn to eliminate defensive null checks by designing safe APIs with Optional, analyzing common anti-patterns tied to its usage. Finally, we explore Parallel Streams to process millions of rows of data across multiple CPU cores. Through a practical architecture discussion around the critical 'N * Q' rule, we learn to evaluate exactly when parallel execution provides decisive performance gains, and when it merely creates unwanted overhead.
Recommendation & Next Steps

Secure the logic of your functional streams by moving on to 'TDD & JUnit: Quality in Java' to build a complete testing strategy.

Format Workshop
Duration 1 day
Level Professional
Instructor Andreas Olsson
Price per group $2,900

Standard price per group (up to 12 participants) for remote delivery. Additional costs apply for onsite delivery.

Tech Stack
Functional Streams Lambdas Clean Code Java 21 Java 25
Andreas Olsson

Your Instructor

Andreas Olsson

Expertise through Active Learning

Java and the Spring Framework have been my core focus for over 20 years. Today, my mission is primarily to help organizations step into the future by integrating intelligent agents and AI-driven features into modern Java systems.

Actlea stands for Active Learning – the philosophy that programming is best learned by writing code, not by watching slides. My workshops focus on intensive, hands-on exercises designed to solve real-world problems.

I deliver proven training concepts globally across all timezones. While I specialize in remote delivery, I love to travel for onsite workshops. My modules are ready for immediate impact but can be tailored to your team's specific requirements.

Connect on LinkedIn

Enterprise teams trained by Actlea

Academic Work
Handelsbanken
Scania
Swedbank
CGI
SEB
Participant Reviews

What past participants say

Read about the pedagogical approach, the hands-on labs, and the impact on daily work.

Related Training

spring boot Professional

Spring Boot Foundations: Expert Track

5 days
Group Rate: On Request

The ultimate 5-day Spring Boot 3 training. From beans and REST to Thymeleaf, Security, TDD, and an introduction to Spring AI.

  • Core Spring: Beans & Auto-config
  • REST API & Spring MVC (Thymeleaf)
  • Spring Data JPA & Persistence
java Professional

Modern Java Fast-Track

1 day
Group Rate: $2,900

Upgrade your codebase by mastering Data-Oriented Programming, Java 21, and Virtual Threads.

  • Records & Text Blocks
  • Data-Oriented Programming (DOP)
  • Sealed Interfaces & Type Safety
spring ai Professional

Spring AI Jumpstart: Professional

1 day
Group Rate: $2,900

Build vendor-agnostic AI services in Spring AI. Learn to integrate leading LLMs like OpenAI and Anthropic through a unified interface.

  • Vendor-Agnostic LLM Integration
  • ChatClient & Portable Prompts
  • Structured Output & BeanMapping
Take the next step

Ready to elevate your
team's expertise?

Book a single workshop, combine modules into a package, or plan a full-scale bootcamp. My training is built on proven standard modules, ready to be delivered immediately to your team, regardless of your location.

  • Expert standard modules for senior teams
  • Global delivery across all time zones
  • Fixed group rate for up to 12 participants (remote)
  • Flexible delivery: Remote or On-site

Get in touch for a quote or to discuss availability.