Skip to content

Combined Training: Java Streams Basics + Advanced

If you really want to master Java Streams, you shouldn’t split basics and advanced across two separate training blocks. Knowledge builds better in one go: what your team establishes on day one with stream pipelines, flatMap(), and collectors is immediately taken further on days two and three – with custom spliterators, groupingBy(), and the new Stream Gatherers.

In three days, this course takes your team to the full level of the Java Streams API – clearly explained, directly applicable, and cheaper than two separate bookings.

Request now – no obligation
3 days
Individual date
On-site or online
German / English
Customizable content
Certificate of completion

What you’ll learn in this training

This three-day combined training merges the content of two individual courses – Java Streams Basics and Java Streams Advanced – and gives you a practical and in-depth understanding of the Java Stream API: from the basics and best practices to advanced techniques like Custom Collectors and Stream Gatherers.

You could also learn Java Streams in two separate trainings – but the combined package is more efficient: three compact days instead of four, a seamless transition from basics to advanced, and a learning arc that builds on itself without interruption.

On the first day, you’ll learn the functional programming fundamentals and the structure of stream pipelines:

  • Role of intermediate and terminal operations
  • Differences from collections
  • Benefits of lazy evaluation
  • Stream creation using collections, arrays, files, and ranges

All of this is directly applied in hands-on exercises – the perfect foundation for the advanced topics on days two and three.

On days two and three, the focus shifts to efficiency, extensibility, and modern techniques:

  • Developing custom collectors (including characteristics and finisher)
  • Analyzing and optimizing stream pipelines
  • Writing custom spliterators and understanding their performance benefits
  • Infinite streams, directory walking, and file streams
  • Stream Gatherers API (since Java 22, finalized in Java 24): using built-ins, writing custom gatherers, managing state

You’ll gain a deep understanding of how streams work internally – and you’ll be equipped to confidently decide when and how to use streams effectively – and when it’s better not to.

The course concludes with a comprehensive final project, where you’ll model a real-world data processing scenario using streams – from requirements through stream design to a performant solution. We’ll review your results together and discuss best practices for production-ready stream code.

👉 Just looking for the basics? Check out Java Streams Basics – Practical Fundamentals for Beginners.

👉 Only want the advanced topics? Then Java Streams Advanced – Gatherers, Spliterators & More might be the better fit.

Target audience

This course is designed for Java developers who want to learn how to use the Streams API efficiently and elegantly – from the ground up – and then immediately take the next step: focusing on performance, extensibility, and modern features like gatherers or custom spliterators.

It’s ideal for anyone seeking a comprehensive knowledge of Java Streams in a short time – for example, during a technology upgrade, relaunch, or refactoring project.

Agenda

Day 1: Streams Basics

Functional Programming in Java:

  • Lambda expressions: syntax, types, and usage
  • Functional interfaces (Consumer, Supplier, Function, Predicate, etc.)
  • Method references: static, instance, constructor references
  • Hands-on exercises: Lambda expressions vs. anonymous classes

Stream Basics:

  • What is a stream? Conceptual differences from collections
  • Anatomy of a stream pipeline: Source → Intermediate Operations → Terminal Operations
  • Lazy evaluation and its implications
  • Creating streams: from collections, arrays, files, ranges
  • Primitive streams: IntStream, LongStream, DoubleStream
  • Hands-on exercises: First stream pipelines with primitive streams

Intermediate Operations Deep Dive:

  • Transformations with map(), flatMap(), filter()
  • Selection and sorting: distinct(), sorted(), limit(), skip()
  • Debugging with peek() – used correctly
  • Chaining operations and performance aspects
  • Hands-on exercises: More complex data processing

Terminal Operations:

  • collect() – the most versatile terminal operator
  • Built-in collectors: toList(), toSet(), toMap()
  • forEach(), forEachOrdered()
  • reduce() for aggregations
  • Finding operations: findFirst(), findAny()
  • Matching operations: allMatch(), anyMatch(), noneMatch()
  • Hands-on exercises: Terminal operations with standard collectors

Days 2 and 3: Streams Advanced

Advanced Collectors and Reduce Operations:

  • Aggregation with reduce(): concepts and practical use
  • Debugging with peek(): when it’s helpful and when not
  • Grouping: groupingBy(), partitioningBy()
  • Downstream collectors: counting(), summingInt(), averagingDouble()
  • Nested grouping and complex aggregations
  • Joining strings with joining()
  • Hands-on: complex data analysis with collectors

Building Custom Collectors:

  • Understanding the Collector interface: supplier(), accumulator(), combiner(), finisher()
  • Characteristics: CONCURRENT, IDENTITY_FINISH, UNORDERED
  • Implementing simple custom collectors
  • More complex use cases: collecting custom objects
  • Hands-on: writing your own collectors

Stream Performance and Spliterator Basics:

  • When to use streams vs. traditional loops
  • Performance pitfalls: boxing/unboxing, long pipelines
  • Parallel streams: when they make sense, common fork/join pool
  • Memory efficiency and large datasets
  • Understanding spliterators and their role
  • Spliterator characteristics: ORDERED, SIZED, SUBSIZED, CONCURRENT, etc.
  • How characteristics affect stream performance

Legacy Code Refactoring Workshop:

  • Refactoring session: transforming loops into streams
  • Identifying good refactoring candidates
  • Step-by-step transformation of legacy code
  • Performance comparisons: before vs. after
  • Readability vs. performance trade-offs
  • When refactoring is worthwhile – and when it’s not
  • Hands-on: multiple legacy scenarios

Advanced Stream Patterns and Custom Spliterators:

  • Conditional operations with Optional
  • Error handling in streams
  • Implementing custom spliterators for specific data structures
  • Spliterator patterns: tryAdvance(), trySplit(), estimateSize()
  • Improving parallelism with custom spliterators
  • File streams: reading lines, directory walking
  • Infinite streams: generate(), iterate()
  • Hands-on: building a custom spliterator

Stream Gatherers (since Java 22, finalized in Java 24):

  • What are stream gatherers and why were they introduced
  • Understanding the Gatherer interface: integrator(), combiner(), finisher()
  • Built-in gatherers: fold(), scan(), windowFixed(), windowSliding()
  • Implementing your own gatherers
  • State management in gatherers
  • Hands-on: building gatherers for specific use cases

Integration and Architecture Patterns:

  • Streams in repository patterns
  • Functional programming principles with streams
  • Designing stream-based APIs
  • Migration strategies: legacy code to streams
  • Anti-patterns and debugging: avoiding common mistakes
  • Testing stream-based code

Workshop and Problem Solving:

  • Complex real-world project: end-to-end stream pipeline
  • Code review session: analyzing participant code
  • Performance tuning based on real examples
  • Q&A and individual use cases
  • Summary of best practices

Is this the training that will move your team forward?

Request now – no obligation

Why learn with me?

I’ve been working with Java for over 20 years – as a developer, CTO, trainer, author, and speaker.

In that time, I’ve helped companies modernize complex Java systems, write performant code, and develop their teams sustainably.

With HappyCoders.eu, I’ve built one of the most widely read Java blogs in the German-speaking world, and I regularly speak at conferences and user groups.

My goal: to teach complex topics in a way that is understandable, practical, and immediately applicable.

Rated 4.97 out of 5 on ProvenExpert

More about me

Any questions?

Participation & Booking

Can individuals book this training?

This training can only be booked for teams. If you’d like to attend as an individual, I offer two courses (in German) through ppedv:

How many participants are possible?

I recommend a maximum of 12 participants per training – that way I can give everyone individual attention. There is no minimum: I charge per training, not per person.

How does booking work?

The easiest way is the request form or an email to schulung@happycoders.eu. Right after submitting, you can book a video call via Calendly, where we discuss the details. You’ll then receive a concrete offer from me.

Prerequisites

What prior Java experience is required?

The course requires solid basic Java knowledge – ideally at least two years of practical experience. Since the first day starts with lambda expressions and functional interfaces, you don’t need to know these topics in advance. However, experience with collections and the basic Java type system is important, so we can dive straight into the stream pipeline concepts.

What technical requirements do we need?

All participants need an up-to-date IDE with at least Java 24 – I use IntelliJ IDEA myself. Java 24 or later should also be installed in the terminal, as we’ll run some of the exercises there.

Schedule & Content

What does a training day look like?

Each day has six hours of net training time – usually with two short breaks and a longer lunch break in between. We align the exact schedule with your working hours – that’s flexible.

How much time is theory, how much is practice?

About half theory, half practice: a short theory phase is followed directly by applying it to code – with examples from real projects. Listening alone doesn’t help much; the knowledge has to be used immediately for it to stick.

Can we adjust or prioritize individual agenda topics?

Yes, that’s no problem. Dropping topics or weighting them differently – as long as I don’t have to restructure the training materials, there are no extra costs.

If you need more extensive changes – for example, combining content from different courses or adding entirely new topics – I’ll be happy to prepare an individual offer.

What exactly does “customizable content” mean?

Within the existing agenda, the weighting can be adjusted: shortening topics, setting priorities, changing the order. That’s free of charge.

Beyond that, more far-reaching adjustments are possible – such as combining content from different courses or completely new topic blocks. This involves extra effort, so I’ll prepare an individual offer for it.

Format & Materials

Which platform do we use for virtual training?

We usually use Zoom. If you prefer your own platform – for example, Microsoft Teams or Google Meet – I’m happy to work with that. Just let me know in advance.

Do participants receive materials to keep?

Yes. Before the training, you’ll receive the exercises as a Git repository so you can get started right away. After the training, you’ll also receive the slides – including all solutions to the exercises.

Prices & Costs

What do the travel expenses include?

Travel expenses are charged as a flat rate – depending on the training location and the number of overnight stays required. The exact amount is part of the individual offer I’ll send you.

Are there discounts for booking multiple trainings?

Yes. For multiple booked trainings or follow-up bookings, I can offer a volume discount. We’ll discuss this in the video call, and I’ll include it in the offer.

Is this a good fit for your team?

Just write to me – I usually reply within 24 hours.
Or book a free video call right away, and we’ll discuss everything important.

Request now – no obligation