Udemy
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
Claude Code: Upgrade Spring Boot 2 to 4 and Java 11 to 25
New

Claude Code: Upgrade Spring Boot 2 to 4 and Java 11 to 25

Use AI safely on legacy code: characterization tests, hooks, skills and plan mode, on a real Spring Boot service
Created byDaniel R
Last updated 10/2026
English

What you'll learn

  • Set up Claude Code for a legacy upgrade with a project memory file, permission rules, plan mode and hooks
  • Freeze a REST API's behavior with characterization tests before changing any version
  • Upgrade Java 11 to 21 and 25, and Spring Boot 2.7 to 3.5 and 4.1, one verified step at a time
  • Handle the real breaking changes: Jakarta EE, Spring Security 6, Hibernate 6, Jackson 3 and the new Spring Boot 4 starters
  • Review AI-generated upgrade diffs with a reviewer subagent and a human checklist
  • Run the same upgrade process headless with claude -p in scripts and CI

Course content

6 sections • 21 lectures • 1h 1m total length
  • Welcome2:25
  • The upgrade map: versions, support dates and our path2:28
  • Set up your machine1:54

Requirements

  • Working knowledge of Java and the basics of Spring Boot (controllers, JPA, tests)
  • Maven and Git installed; JDK 21 and JDK 25 (any distribution)
  • A paid Claude plan that includes Claude Code, or an Anthropic API key (Claude Code is not free)

Description

This course contains the use of artificial intelligence.

Spring Boot 2.7 lost its free support in 2023, and since June 2026 the whole 3.x line is out of open-source support as well. If your team still runs services on these versions, the upgrade is on the roadmap whether you like it or not. It is also exactly the kind of long, repetitive, test-driven work where an AI coding agent can save weeks, as long as it is set up so it cannot quietly break your API.

In this course you upgrade one realistic legacy service, ShipTrack, a parcel tracking REST API on Java 11 and Spring Boot 2.7, all the way to Spring Boot 4.1 and Java 25, with Claude Code doing the heavy lifting. Nothing is staged: every Claude Code session you see is a real run replayed from its transcript, and every diff and build log comes from the course repository, which you can download and check out step by step with git tags. The raw transcripts of every Claude Code run are included too.

You will not paste one giant prompt and hope. You will build a small, reusable upgrade kit and run the same loop for every step:

  • A project memory file (the CLAUDE file) as your working agreement: build commands, upgrade rules and a definition of done

  • Permission rules and plan mode, so Claude proposes and you approve

  • Characterization tests that freeze today's API behavior before any version changes

  • Hooks that block edits to those tests and stop Claude from finishing on a red build

  • One skill per upgrade step, with checklists taken from the official migration guides

  • A reviewer subagent that looks for hidden behavior changes before you commit

  • Headless runs with claude -p, for scripts and CI

This is not a highlight reel. You will see Claude Code find a real production bug before the upgrade starts, refuse to bypass a guardrail, and verify APIs in the actual jars. You will also see it make real mistakes: a miscounted test run, two wrong claims in a plan, a wrong root cause, a check that hid a failing build. None of them reached a commit, and you will learn exactly which guardrail caught each one. The whole upgrade took about two hours of Claude time and about 24 USD of API-equivalent usage, and you will see the numbers.

The upgrade path follows the rule of one variable at a time: safety net, Java 21 on Spring Boot 2.7, removing deprecated APIs while still on 2.7, Spring Boot 3.5 (Jakarta EE, Spring Security 6, Hibernate 6, springdoc), Spring Boot 4.1 (Jackson 3, modular starters, test changes) and finally Java 25. Along the way you see the real problems these upgrades cause, including the silent ones: renamed properties that are simply ignored, JSON that changes shape, and security rules whose order changes their meaning.

About AI use in this course: the narration uses an AI-generated voice. Claude Code, an AI coding tool, is the subject of the course and performed the upgrade steps shown on screen. Every upgrade step was verified by the full test suite, and all prompts and transcripts are included so you can check the work yourself.

Who this course is for:

  • Java developers who maintain Spring Boot 2.x or 3.x services that must be upgraded
  • Tech leads who want a repeatable, reviewable way to use AI on legacy code
  • Developers who use Claude Code for small tasks and want a safe process for large, risky changes