Spring Boot Mastery Path¶
Spring Boot is how a very large share of the Java world builds backend services. Under
the hood it is the Spring Framework — an inversion-of-control container that creates your
objects, wires them together, and wraps them in proxies that add transactions, security,
and caching — plus an opinionated layer that configures all of that for you based on what
is on your classpath. Put spring-boot-starter-webmvc in your build and you get an
embedded Tomcat, JSON serialization, and a dispatcher servlet without writing a line of
setup. That convenience is also the main source of confusion: when something behaves
unexpectedly, the answer is usually in a bean, proxy, or auto-configuration you never saw.
This course teaches you to build real services with Spring Boot and to see through the magic. It assumes you already know Java — classes, interfaces, generics, lambdas, records, exceptions, and a build tool at a basic level. If you do not, start with the Java Mastery Path, which covers the language itself; here we spend no time on Java syntax.
Level 1 builds a REST API with validation, error responses in the standard
application/problem+json format, typed configuration, and logging. Level 2 adds a real
database through Spring Data JPA and Hibernate, Flyway migrations, transactions, a proper
test suite, and Spring Security with JWTs. Level 3 opens the machinery — how
auto-configuration decides what to create, how AOP proxies implement @Transactional and
@Cacheable, why lazy loading causes N+1 queries — and adds caching, async work, Kafka
messaging, resilient HTTP clients, and Actuator. Level 4 is about running services for
real: microservices and Spring Cloud, WebFlux versus virtual threads, performance, native
images, containers, tracing, hardening, deployment, and a capstone.
Every lesson ends with a How It Actually Works section that explains the mechanism
rather than just the annotation: the proxy behind @Transactional and why calling a
transactional method from the same class silently skips the transaction, the
@Conditional checks that decide which auto-configurations apply, the bean lifecycle
from definition to destruction, and Hibernate's persistence context with its dirty
checking.
About versions and outputs
Code in this course targets Spring Boot 4.x (the line Spring Initializr generates
today, built on Spring Framework 7) with Java 17 or newer — Java 21 or 25 is
recommended so you can use virtual threads. Boot 3.x is still widespread in existing
codebases and nearly everything here applies to it too; where Boot 4 changed a name
or package (for example the spring-boot-starter-webmvc starter or the test-slice
packages), the lesson points out the 3.x equivalent. Builds use Maven; Gradle
equivalents are shown where they differ in an interesting way. Console output shown in
lessons was produced by actually running the code; where something needs an external
service (PostgreSQL, Kafka, an identity provider, a cloud platform) and it was not run
for this course, the lesson says so rather than inventing output.
How the program is organized¶
| Level | Focus | Modules |
|---|---|---|
| Level 1 · Entry | What Spring is, Initializr & project layout, dependency injection, beans & scanning, configuration & profiles, REST controllers, validation, error handling, logging | 9 topics + 1 project (task tracker API) |
| Level 2 · Intermediate | Spring Data JPA & Hibernate, entities & relationships, repositories & queries, transactions, Flyway, testing, Spring Security, JWT resource server, OpenAPI docs | 9 topics + 1 project (secured library API) |
| Level 3 · Advanced | Auto-configuration internals, AOP & proxies, N+1 & fetch strategies, caching, async & scheduling, Kafka, HTTP clients & resilience, Actuator, bean lifecycle & events | 9 topics + 1 project (event-driven order service) |
| Level 4 · Master | Spring Cloud & microservices, WebFlux vs virtual threads, performance, GraalVM native, containers, observability, security hardening, deployment, modular architecture | 9 topics + 1 capstone (production-ready service) |
How to use this site¶
- Work through the levels in order. Level 3 explains why the annotations you used in Levels 1 and 2 behave the way they do, and it lands much better once you have been surprised by them at least once.
- Build the code. Generate a project from start.spring.io,
paste the classes in, and run
./mvnw spring-boot:runor./mvnw test. Break things on purpose — remove an annotation, rename a property — and read the startup failure. - Do the Exercise at the end of each lesson. Each project (module 10) grows out of the exercises before it.
- Keep one repository per level. By the end you will have a validated REST API, a secured database-backed service with tests, an event-driven service using Kafka, and a containerized, observable capstone.
- For the language itself, see the Java Mastery Path; for testing in depth, Java Testing; for the architecture side, the System Design Mastery Path.
Start here → Level 1 · Entry
🎥 Prefer video? Watch the Mastery Path video series on YouTube — Shorts and full walkthroughs of lessons across the series.
More from the Mastery Path series¶
Free, structured, module-wise training across 68 other languages, platforms and disciplines:
Languages
Web Frameworks
Testing & QA
Security
Cloud Platforms
Data & Analytics
AI / ML / LLM
Embedded Systems
Leadership & Management
Professional Skills
Careers & Interviews
Process & APIs
Infrastructure & Ops