SlideShare a Scribd company logo
Dan Vega
Spring Developer Advocate
Spring Boot 3
& Beyond
© 2020 Spring. A VMware-backed project.
Cover w/ Image
About Me
● Husband & Father
● Cleveland, OH
● Software Developer 22+ Years
● Spring Developer Advocate
● Content Creator www.danvega.dev
● Writing - Blog & Newsletter
● YouTuber
● @therealdanvega
Spring Boot 3 And Beyond
Cover w/ Image
A new generation of Spring for 2023 and beyond
● Spring Boot 3
● JDK 17+
● Jakarta EE 9 / 10 (Jakarta namespace)
● AOT (Ahead-Of-Time) Compilation
● Observability (Micrometer)
● But wait, there's more!
● Spring Boot 3.1
● Docker Compose Module
● Spring Boot 3.2
● Virtual Threads (“Project Loom”)
Spring Boot 3.0
Java and Jakarta
Spring Boot 3 And Beyond
Baseline: JDK 17 LTS
Language: text blocks, switch expressions
Core libraries: collection factory methods, etc
Type system: records, sealed classes
Module system: module introspection, module path scanning
Performance Improvements
Security Updates
Empowering the framework as well as applications
JDK 17 / 20 / 21
Spring generally embraces the latest JDK/JVM versions
JDK 17 baseline retained for long-term support purposes
E.g. in JDK 20: virtual threads, record patterns (preview)
JDK 21 on the horizon as next long-term support release
Consider upgrading your JDK along with Spring Framework 6.x
Baseline: Jakarta EE 9
A new namespace: Java EE 8 → Jakarta EE 9
Servlet API 5.0 : javax.servlet → jakarta.servlet
JPA 3.0 : javax.persistence → jakarta.persistence
Bean Validation 3.0 : javax.validation → jakarta.validation
Dependency Injection 2.0 : javax.inject → jakarta.inject
All further API evolution to happen in jakarta namespace
Migrating with the help of IDEs & Tools
Jakarta EE 9 / 10
Tomcat 10.0 / 10.1 – Servlet API 5.0 / 6.0
Jetty 11 / 12 – Servlet API 5.0 / 6.0
Undertow 2.3 – Servlet API 6.0
Hibernate ORM 6.1 – JPA 3.0 / 3.1
Hibernate Validator 7.0 / 8.0 – Bean Validation 3.0
Note: API upgrades not coupled to major provider versions anymore!
Ahead-of-Time
What is it?
● What is Ahead of Time Compilation?
● Java is a dynamic language
● Runtime hints for reflection, resources, serialization, proxies
● Precondition for GraalVM native executables
● Reducing startup time and memory footprint in production
● AOT is a tradeoff; extra build setup and less flexibility at runtime
Why Compile to Native?
Use Cases for Native Images
Observability
Observability
Observability is the ability to observe the internal state of a running
system from the outside. It consists of the three pillars logging, metrics
and traces.
Direct Observability instrumentation with Micrometer Observation in
several parts of the Spring Framework.
RestTemplate and WebClient are instrumented to produce HTTP client
request observations.
Spring Cloud Sleuth no longer needed for Distributed Tracing
Observation API
Spring Boot 3 - But wait there’s more!
HTTP Interface Client
RFC 7807 Problem Details
Spring Data 2022
Spring Security 6
Spring Authorization Server 1.0
Spring for GraphQL 1.1
More
Spring Boot 3.1
Spring Boot 3.1
Using Testcontainers at Development Time
Docker Compose spring-boot-docker-compose module
Auto-Configuration for Spring Authorization Server
Building Docker Images with Maven or Gradle
Spring for GraphQL 1.2
Dependency Upgrades
https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-3.1-Release-Notes
Docker Compose Module
Spring Boot 3 And Beyond
Spring Boot 3 And Beyond
Demo
Spring Boot 3.2
Project Loom / Virtual Threads
What is a Thread in Java
● Java is Multithreaded by default
● java.lang.Thread
● Abstraction over operating system threads
● Every thread is essentially a wrapper over an OS thread
● OS/JVM thread = platform thread
● Platform threads are expensive
● Take a lot of memory / take time to create & destroy
● Traditional threads are stored on the JVM stack
Project Loom is to intended to explore,
incubate and deliver Java VM features and
APIs built on top of them for the purpose of
supporting easy-to-use, high-throughput
lightweight concurrency and new
programming models on the Java platform.
Project Loom
Project Loom includes the following JEPs.
● JEP 425: Virtual Threads (Preview) was integrated in JDK 19
● JEP 428: Structured Concurrency (Incubator) was integrated in JDK 19.
● JEP 429: Scoped Values (Incubator) has been integrated for JDK 20.
“Project Loom” Virtual Threads
Virtual Threads
● JDK 19 includes Virtual Threads as a Preview Feature
● Targeted for JDK 21
● Not Linked to an OS thread
● Use the heap for the stack (potential implications for GC)
● Have their own scheduler
● Created for a task and then allowed to terminate
● Do not pool virtual threads
Thread-Per-Request
Spring Boot 3 And Beyond
Spring Boot 3 And Beyond
Spring Boot 3 And Beyond
Spring Boot 3 And Beyond
Spring Boot 3 And Beyond
Virtual Threads &
Spring Applications
Embracing Virtual Threads in Spring Applications
Web Applications.
● Servlet callback based on Input / Output Stream
● Tomcat / Jetty Executor setup for dispatching to request handlers
● “Loom-ready” database drivers, scalable connection pool setup
● Ideally no code changes in the main application codebase
● Virtual threads supported in GraalVM Native Image as well
● Significant scalability benefits for database driven web applications
Embracing Virtual Threads in Spring Applications
Messaging / Scheduling
● Spring managed task executors with virtual thread options
● JMS Message Listener containers
● @Scheduled handler methods
● Many of those listeners and handlers methods trigger I/O operations
Embracing Virtual Threads in Spring Applications
Where it doesn’t make sense
● Purely CPU bound handler methods
● Reactive based web applications
Virtual Threads
Loom vs Reactive Programming
● Virtual Threads provide a different scalability mechanism
● Traditional imperative programming style
● Empowering Spring MVC to reach maximum scalability
● Spring Webflux as an architecture for stream based processing
● Reactive: Stream based processing not primarily for scalability (anymore)
Demo
Spring Framework 6.0 – available now
Foundation for Spring Boot 3.0 & 3.1
Production-ready on JDK 17 LTS
Regular stream of 6.0.x releases in 2023
Spring Framework 6.1 – November 2023
Foundation for Spring Boot 3.2 & 3.3
Production-ready on JDK 17 & 21 LTS
Release candidate expected in October 2023
Thank you
Contact me at dvega@vmware.com
@therealdanvega
Copyright © 2020 VMware, Inc. or its affiliates.

More Related Content

PPT
Spring Core
PDF
All About JSON and ClickHouse - Tips, Tricks and New Features-2022-07-26-FINA...
PDF
Recent Trends in Personalization at Netflix
PDF
Data engineering zoomcamp introduction
DOCX
High level design document template
PDF
IBM WebSphere application server
PPTX
API Docs with OpenAPI 3.0
PDF
Making The Move To Java 17 (JConf 2022)
Spring Core
All About JSON and ClickHouse - Tips, Tricks and New Features-2022-07-26-FINA...
Recent Trends in Personalization at Netflix
Data engineering zoomcamp introduction
High level design document template
IBM WebSphere application server
API Docs with OpenAPI 3.0
Making The Move To Java 17 (JConf 2022)

What's hot (20)

PDF
SpringOne Tour: Spring Boot 3 and Beyond
PDF
Spring Native and Spring AOT
PPTX
Spring Boot
PDF
Spring Boot
PPT
Introduction to Visual Studio.NET
PPTX
Spring boot Introduction
PPTX
Spring boot
PPTX
Maven ppt
PDF
Building .NET Microservices
PDF
Next-Generation Cloud Native Apps with Spring Cloud and Kubernetes
PDF
Deep Dive Java 17 Devoxx UK
PPTX
Migrating to Java 11
PDF
Understanding Reactive Programming
PDF
Spring Boot
PDF
Gradle Introduction
PPTX
Reactive programming
PDF
Microservice With Spring Boot and Spring Cloud
PDF
NestJS
PDF
PUC SE Day 2019 - SpringBoot
PPTX
Introduction to Spring Boot
SpringOne Tour: Spring Boot 3 and Beyond
Spring Native and Spring AOT
Spring Boot
Spring Boot
Introduction to Visual Studio.NET
Spring boot Introduction
Spring boot
Maven ppt
Building .NET Microservices
Next-Generation Cloud Native Apps with Spring Cloud and Kubernetes
Deep Dive Java 17 Devoxx UK
Migrating to Java 11
Understanding Reactive Programming
Spring Boot
Gradle Introduction
Reactive programming
Microservice With Spring Boot and Spring Cloud
NestJS
PUC SE Day 2019 - SpringBoot
Introduction to Spring Boot
Ad

Similar to Spring Boot 3 And Beyond (20)

PDF
Spring Update | July 2023
PPTX
Micronaut: A new way to build microservices
PDF
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
PPT
J2EE Batch Processing
PPTX
Advance java prasentation
PPTX
WebLogic Developer Experience and Java EE 6
PDF
A Hitchhiker's Guide to Cloud Native Java EE
PDF
A Hitchhiker's Guide to Cloud Native Java EE
PPT
1.INTRODUCTION TO JAVA_2022 MB.ppt .
PPTX
Quarkus and GraalVM
PPTX
Java dev mar_2021_keynote
PPT
Cloud compiler - Minor Project by students of CBPGEC
PPT
Apache Tomcat 7 by Filip Hanik
PDF
What's coming in Airflow 2.0? - NYC Apache Airflow Meetup
PDF
Java 40 versions_sgp
PPT
Java2 platform
PDF
Java 9 and Beyond
PPT
Gwt Presentation1
PPT
EmbeddedJavaSmall.ppt
PDF
node.js 실무 - node js in practice by Jesang Yoon
Spring Update | July 2023
Micronaut: A new way to build microservices
Web Component Development Using Servlet & JSP Technologies (EE6) - Chapter 1...
J2EE Batch Processing
Advance java prasentation
WebLogic Developer Experience and Java EE 6
A Hitchhiker's Guide to Cloud Native Java EE
A Hitchhiker's Guide to Cloud Native Java EE
1.INTRODUCTION TO JAVA_2022 MB.ppt .
Quarkus and GraalVM
Java dev mar_2021_keynote
Cloud compiler - Minor Project by students of CBPGEC
Apache Tomcat 7 by Filip Hanik
What's coming in Airflow 2.0? - NYC Apache Airflow Meetup
Java 40 versions_sgp
Java2 platform
Java 9 and Beyond
Gwt Presentation1
EmbeddedJavaSmall.ppt
node.js 실무 - node js in practice by Jesang Yoon
Ad

More from VMware Tanzu (20)

PDF
Spring into AI presented by Dan Vega 5/14
PDF
What AI Means For Your Product Strategy And What To Do About It
PDF
Make the Right Thing the Obvious Thing at Cardinal Health 2023
PPTX
Enhancing DevEx and Simplifying Operations at Scale
PPTX
Platforms, Platform Engineering, & Platform as a Product
PPTX
Building Cloud Ready Apps
PDF
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
PDF
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
PDF
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
PPTX
tanzu_developer_connect.pptx
PDF
Tanzu Virtual Developer Connect Workshop - French
PDF
Tanzu Developer Connect Workshop - English
PDF
Virtual Developer Connect Workshop - English
PDF
Tanzu Developer Connect - French
PDF
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
PDF
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
PDF
SpringOne Tour: The Influential Software Engineer
PDF
SpringOne Tour: Domain-Driven Design: Theory vs Practice
PDF
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
PDF
SpringOne Tour: Doing Progressive Delivery with your Team
Spring into AI presented by Dan Vega 5/14
What AI Means For Your Product Strategy And What To Do About It
Make the Right Thing the Obvious Thing at Cardinal Health 2023
Enhancing DevEx and Simplifying Operations at Scale
Platforms, Platform Engineering, & Platform as a Product
Building Cloud Ready Apps
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
tanzu_developer_connect.pptx
Tanzu Virtual Developer Connect Workshop - French
Tanzu Developer Connect Workshop - English
Virtual Developer Connect Workshop - English
Tanzu Developer Connect - French
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: The Influential Software Engineer
SpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Doing Progressive Delivery with your Team

Recently uploaded (20)

PDF
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
PDF
GDG Cloud Iasi [PUBLIC] Florian Blaga - Unveiling the Evolution of Cybersecur...
PDF
Empathic Computing: Creating Shared Understanding
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PPTX
Understanding_Digital_Forensics_Presentation.pptx
DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
Big Data Technologies - Introduction.pptx
PDF
Electronic commerce courselecture one. Pdf
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
GDG Cloud Iasi [PUBLIC] Florian Blaga - Unveiling the Evolution of Cybersecur...
Empathic Computing: Creating Shared Understanding
The Rise and Fall of 3GPP – Time for a Sabbatical?
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
Advanced methodologies resolving dimensionality complications for autism neur...
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
NewMind AI Weekly Chronicles - August'25 Week I
Dropbox Q2 2025 Financial Results & Investor Presentation
CIFDAQ's Market Insight: SEC Turns Pro Crypto
Understanding_Digital_Forensics_Presentation.pptx
The AUB Centre for AI in Media Proposal.docx
Big Data Technologies - Introduction.pptx
Electronic commerce courselecture one. Pdf
Per capita expenditure prediction using model stacking based on satellite ima...
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Review of recent advances in non-invasive hemoglobin estimation
Reach Out and Touch Someone: Haptics and Empathic Computing
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton

Spring Boot 3 And Beyond

  • 1. Dan Vega Spring Developer Advocate Spring Boot 3 & Beyond © 2020 Spring. A VMware-backed project.
  • 2. Cover w/ Image About Me ● Husband & Father ● Cleveland, OH ● Software Developer 22+ Years ● Spring Developer Advocate ● Content Creator www.danvega.dev ● Writing - Blog & Newsletter ● YouTuber ● @therealdanvega
  • 4. Cover w/ Image A new generation of Spring for 2023 and beyond ● Spring Boot 3 ● JDK 17+ ● Jakarta EE 9 / 10 (Jakarta namespace) ● AOT (Ahead-Of-Time) Compilation ● Observability (Micrometer) ● But wait, there's more! ● Spring Boot 3.1 ● Docker Compose Module ● Spring Boot 3.2 ● Virtual Threads (“Project Loom”)
  • 8. Baseline: JDK 17 LTS Language: text blocks, switch expressions Core libraries: collection factory methods, etc Type system: records, sealed classes Module system: module introspection, module path scanning Performance Improvements Security Updates Empowering the framework as well as applications
  • 9. JDK 17 / 20 / 21 Spring generally embraces the latest JDK/JVM versions JDK 17 baseline retained for long-term support purposes E.g. in JDK 20: virtual threads, record patterns (preview) JDK 21 on the horizon as next long-term support release Consider upgrading your JDK along with Spring Framework 6.x
  • 10. Baseline: Jakarta EE 9 A new namespace: Java EE 8 → Jakarta EE 9 Servlet API 5.0 : javax.servlet → jakarta.servlet JPA 3.0 : javax.persistence → jakarta.persistence Bean Validation 3.0 : javax.validation → jakarta.validation Dependency Injection 2.0 : javax.inject → jakarta.inject All further API evolution to happen in jakarta namespace
  • 11. Migrating with the help of IDEs & Tools
  • 12. Jakarta EE 9 / 10 Tomcat 10.0 / 10.1 – Servlet API 5.0 / 6.0 Jetty 11 / 12 – Servlet API 5.0 / 6.0 Undertow 2.3 – Servlet API 6.0 Hibernate ORM 6.1 – JPA 3.0 / 3.1 Hibernate Validator 7.0 / 8.0 – Bean Validation 3.0 Note: API upgrades not coupled to major provider versions anymore!
  • 14. What is it? ● What is Ahead of Time Compilation? ● Java is a dynamic language ● Runtime hints for reflection, resources, serialization, proxies ● Precondition for GraalVM native executables ● Reducing startup time and memory footprint in production ● AOT is a tradeoff; extra build setup and less flexibility at runtime
  • 15. Why Compile to Native?
  • 16. Use Cases for Native Images
  • 18. Observability Observability is the ability to observe the internal state of a running system from the outside. It consists of the three pillars logging, metrics and traces. Direct Observability instrumentation with Micrometer Observation in several parts of the Spring Framework. RestTemplate and WebClient are instrumented to produce HTTP client request observations. Spring Cloud Sleuth no longer needed for Distributed Tracing
  • 20. Spring Boot 3 - But wait there’s more! HTTP Interface Client RFC 7807 Problem Details Spring Data 2022 Spring Security 6 Spring Authorization Server 1.0 Spring for GraphQL 1.1 More
  • 22. Spring Boot 3.1 Using Testcontainers at Development Time Docker Compose spring-boot-docker-compose module Auto-Configuration for Spring Authorization Server Building Docker Images with Maven or Gradle Spring for GraphQL 1.2 Dependency Upgrades https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-3.1-Release-Notes
  • 26. Demo
  • 28. Project Loom / Virtual Threads
  • 29. What is a Thread in Java ● Java is Multithreaded by default ● java.lang.Thread ● Abstraction over operating system threads ● Every thread is essentially a wrapper over an OS thread ● OS/JVM thread = platform thread ● Platform threads are expensive ● Take a lot of memory / take time to create & destroy ● Traditional threads are stored on the JVM stack
  • 30. Project Loom is to intended to explore, incubate and deliver Java VM features and APIs built on top of them for the purpose of supporting easy-to-use, high-throughput lightweight concurrency and new programming models on the Java platform.
  • 31. Project Loom Project Loom includes the following JEPs. ● JEP 425: Virtual Threads (Preview) was integrated in JDK 19 ● JEP 428: Structured Concurrency (Incubator) was integrated in JDK 19. ● JEP 429: Scoped Values (Incubator) has been integrated for JDK 20.
  • 32. “Project Loom” Virtual Threads Virtual Threads ● JDK 19 includes Virtual Threads as a Preview Feature ● Targeted for JDK 21 ● Not Linked to an OS thread ● Use the heap for the stack (potential implications for GC) ● Have their own scheduler ● Created for a task and then allowed to terminate ● Do not pool virtual threads
  • 39. Virtual Threads & Spring Applications
  • 40. Embracing Virtual Threads in Spring Applications Web Applications. ● Servlet callback based on Input / Output Stream ● Tomcat / Jetty Executor setup for dispatching to request handlers ● “Loom-ready” database drivers, scalable connection pool setup ● Ideally no code changes in the main application codebase ● Virtual threads supported in GraalVM Native Image as well ● Significant scalability benefits for database driven web applications
  • 41. Embracing Virtual Threads in Spring Applications Messaging / Scheduling ● Spring managed task executors with virtual thread options ● JMS Message Listener containers ● @Scheduled handler methods ● Many of those listeners and handlers methods trigger I/O operations
  • 42. Embracing Virtual Threads in Spring Applications Where it doesn’t make sense ● Purely CPU bound handler methods ● Reactive based web applications
  • 43. Virtual Threads Loom vs Reactive Programming ● Virtual Threads provide a different scalability mechanism ● Traditional imperative programming style ● Empowering Spring MVC to reach maximum scalability ● Spring Webflux as an architecture for stream based processing ● Reactive: Stream based processing not primarily for scalability (anymore)
  • 44. Demo
  • 45. Spring Framework 6.0 – available now Foundation for Spring Boot 3.0 & 3.1 Production-ready on JDK 17 LTS Regular stream of 6.0.x releases in 2023
  • 46. Spring Framework 6.1 – November 2023 Foundation for Spring Boot 3.2 & 3.3 Production-ready on JDK 17 & 21 LTS Release candidate expected in October 2023
  • 47. Thank you Contact me at dvega@vmware.com @therealdanvega Copyright © 2020 VMware, Inc. or its affiliates.