Ron Veen

Modern Java: This is not your father's Java anymore

Forget complex reactive paradigms. Java 21's virtual threads deliver massive concurrency with a simple, familiar thread-per-request model.

Modern Java: This is not your father's Java anymore
#1about 3 minutes

Creating immutable data carriers with Java records

Records provide a concise syntax for creating immutable data classes, automatically generating constructors, accessors, equals, and hashCode.

#2about 2 minutes

Controlling class inheritance with sealed classes

Sealed classes and interfaces restrict which other classes or interfaces may extend or implement them, offering more control than final or public.

#3about 5 minutes

Leveraging pattern matching for switches and records

Pattern matching simplifies complex conditional logic by combining type checks and variable extraction within switch expressions and instanceof checks.

#4about 4 minutes

Understanding the new virtual threads model

Virtual threads are lightweight, JVM-managed threads that dramatically increase scalability for concurrent applications without complex reactive code.

#5about 2 minutes

Managing concurrent tasks with structured concurrency

Structured concurrency simplifies multithreaded programming by treating groups of related tasks running in different threads as a single unit of work.

#6about 1 minute

Replacing thread locals with safer scoped values

Scoped values offer an improved way to share immutable data within and across threads for a limited scope, avoiding the pitfalls of thread locals.

#7about 2 minutes

Simplifying Java entry points for new developers

Java now allows for simpler main method declarations and unnamed classes, lowering the barrier to entry for writing basic programs.

#8about 2 minutes

Decluttering code with unnamed variables and patterns

Use the underscore character for unnamed variables and patterns to signify intentionally unused variables, improving code clarity.

#9about 1 minute

Introducing new methods for sequence collections

The new sequenced collection interface adds standardized methods like getFirst, getLast, and reversed to collections with a defined encounter order.

#10about 2 minutes

Using string templates for safer interpolation

String templates provide a more powerful and secure way to perform string interpolation by using template processors like STR and FMT.

#11about 4 minutes

Applying data-oriented programming principles in Java

Combine records, sealed classes, and pattern matching to implement data-oriented programming, where application logic is driven by the structure of the data itself.

Related jobs
Jobs that call for the skills explored in this talk.

Featured Partners

From learning to earning

Jobs that call for the skills explored in this talk.

Java Full Stack


Municipality of Madrid, Spain

45-65K
Intermediate
Java
Angular

Java Developer


Charing Cross, United Kingdom

104K
iOS
Java
REST
Redshift
+5