From setting up your environment through DI and configuration, validation, Spring Data JPA, transactions, testing, Thymeleaf and Spring Security, all the way to a production setup on PostgreSQL and Docker. Twenty lessons that build one task management app from the first line to the last. Every piece of code and every log line was produced by actually running Spring Boot 4.1.1 on Java 21.
The 20 lessons are grouped into five chapters. Working through them in order is the best way, but you are welcome to dip into whatever interests you. Note: Java cannot run inside the browser, so try everything in the project you create in lesson 1.
You take apart the eight-line main that boots Tomcat along with everything else, then bind URLs and methods to receive requests. By the end you can set the status and headers yourself with ResponseEntity.
You get to grips with the DI container at the heart of Spring, move configuration outside, and guard your input with annotations. Finally you standardise error responses on ProblemDetail so they are managed in one place.
You store data with Spring Data JPA and cover DTOs, relationships, search and transactions. Both the N+1 problem and "@Transactional is not working" are confirmed by counting for real.
You write three layers of tests fastest-first, build screens with Thymeleaf, and add sign-in with Spring Security. The service layer you have built up to now is reused without changing a single line.
Logging and Actuator let you see inside the app from outside, and you swap H2 for PostgreSQL. Finally you package it as a Docker image so it runs anywhere else.
Once you have finished all 20 lessons, learn to operate this app in containers with Docker. Membership unlocks every course.