Spring Boot and Java Roadmap: What’s coming and how it affects the backend

Spring Boot 4 and Java 25 require a full review of the entire platform: JSON contracts, security, observability, internal dependencies and runtime behaviour. The version upgrade should be treated as a migration of the entire platform.

This article focuses on a practical question: What should I check before migrating to Spring Boot 4.1.x, how do I perform the migration and what Java changes should be considered for future migrations?

    Written by:

    Jose Gracia Berenguer

    Analyst Programmer (R&D) @ edicom | FullStack developer | Computer Engineer

    Apassionate Full-Stack Developer with a strong focus on web applications and back-end development.
    My web: https://jgracia.es/

    Manuel Gregorio

    Scrum Master

    Scrum Master and Backend software engineer specialising in Java and Spring. Graduate in Computer Engineering and Master’s Degree in Software Systems Engineering and Technology. Author of an international publication on automated testing.

Contents

  1. Glossary
  2. Spring Boot Roadmap
  3. Spring Boot 3.5
  4. Spring Boot 4.0
  5. Migration strategy to Spring Boot 4.1.x
  6. Jackson 3
  7. Security, metrics and silent behaviour
  8. Declarative HTTP clients, gRPC and SSRF
  9. Important APIs to “highlight” for migration
  10. Criteria for considering the migration complete
  11. Java and OpenJDK after 25: what awaits us
  12. Conclusion
  13. Official references and blogs of interest

Glossary

Below are some technical terms mentioned in the article.

  • Heapdump: JVM memory dump. It is useful for diagnosing memory leaks, but may contain tokens, passwords, environment variables, session data or internal information.
  • SSRF: Server-Side Request Forgery. Occurs when an attacker manages to get a server to make HTTP requests to destinations it shouldn’t, for example, localhost, private networks, cloud metadata or internal services.
  • Micrometer / Observation: A layer of metrics, traces and observability that lets you know what the application is doing at runtime, not just whether it is live. 

Spring Boot Roadmap

Before starting the migration to Spring Boot 4, it is advisable to use Spring Boot 3.5 as a baseline cleanup phase: resolving deprecations, reviewing the Actuator exposure and preparing the configuration for cloud environments.

Spring Boot 4.0 is the platform change: Spring Framework 7, Jakarta EE 11, Jackson 3, changes in testing, internal modularization and new rules in autoconfiguration.

Spring Boot 4.1.x consolidates this cycle with relevant capabilities such as gRPC, SSRF mitigation and lazy database connections, provided they are compared against the specific version to be adopted and its migration notes.

The version timeline should serve as a reading map: First, Spring Boot 3.5 as a cleanup phase, then Spring Boot 4.0 as a platform leap, and finally Spring Boot 4.1.x as consolidation of new capabilities and review of production risks. The following table shows the support status of the Spring Boot branches being discussed.

Spring Boot versionSupport statusJava baselineApproach
3.4 / 3.5.xCommercial support/ Active maintenance17Observability maturity
Security in actuators
4.0Active general support17 
recommended 21+ 
Jakarta EE 11
Declarative HTTP Clients and Modularity
4.1.0 (current) Current17 
recommended 21+ 
Native gRPC
SSRF Security
Boot optimization 

Spring Boot 3.5

Spring Boot 3.5 functions as a stabilization version before undertaking a serious migration to 4.1.0. In this phase, the aim is to reduce uncertainty: closing deprecations, reviewing Actuator exposure, and cleaning up configuration before adding the platform changes that come with Spring Boot 4.

Regarding Actuator, exposing the “/actuator/heapdump” endpoint without control is dangerous because a heap dump may contain sensitive information. The typical older configuration was too permissive because, previously, more information than necessary was being published. Now, only the essential endpoints should be enabled and those that could reveal internal state, sensitive metrics or memory dumps should be explicitly protected.

The significant change is a shift from broad exposure to a granular configuration, where only what is necessary is published and under differentiated controls. The following image displays code illustrating the change; previously, everything was included, whereas now it is necessary to define what is exposed.

# Before:
management.endpoints.web.exposure.include=*
# After:
management.endpoints.web.exposure.include=health,info,prometheus
management.endpoint.heapdump.access=none

Another interesting novelty is the import of configuration from environment variables using “spring.config.import=env:”. This lets you inject an entire block of properties, useful in Kubernetes or environments where configuration comes from ConfigMaps or Secrets.

Configuration example:

# Tell Spring to load the configuration from the variable 'CONFIG_PROD_MASIVA'
spring.config.import=env:CONFIG_PROD_MASIVA
spring.config.import=optional:env:CONFIG_PROD_MASIVA
CONFIG_PROD_MASIVA='server.port=8080
feature.payments.enabled=true
spring.datasource.xxxx.maximum-pool-size=20'

 In Kubernetes, the same idea could be loaded from a ConfigMap or Secret managed by the platform:

kubectl create configmap payments-config
    --from-literal=CONFIG_PROD_MASIVA='server.port=8080
feature.payments.enabled=true
clients.billing.base-url=https://billing.internal'

 

The following diagram shows a flow for integrating this ConfigMap up to Spring. This incorporates it into the application environment and the service consumes it already during runtime.

The pattern is useful in deployments where configuration varies by environment. However, limits must be imposed: separate sensitive secrets from non-sensitive configuration, avoid large blocks lacking traceability and document which team controls each value. Its value lies in grouping environment configuration cleanly, rather than creating a black box that is difficult to audit.

Spring Boot 4.0

Migrating to Spring Boot 4.0 changes the foundation on which the application runs. It pulls in Spring Framework 7, Jakarta EE 11, Jackson 3, testing tweaks, autoconfiguration changes and a major ecosystem upgrade.

The new technological framework of Spring Boot 4.0 is better understood by comparing the previous base with the new one. The versions of Spring Framework, Jakarta EE, Servlet, JPA, Kotlin, GraalVM, JUnit and Jackson determine which dependencies compile, which starters remain valid and what behaviour may change at runtime.

ComponentSpring Framework 6.2Spring Framework 7.0
JDK17 baseline, recommended 2117 baseline; latest LTS recommended for validation
Jakarta EE9/1011
Servlet6.06.1 (Tomcat 11, Jetty 12.1)
JPA3.13.2 (Hibernate 7.1/7.2)
Bean Validation3.03.1
Kotlin1.x/2.02.2
GraalVM22.3+25
JUnit56
Jackson2.x3.x default, (2.x deprecated)

Migration strategy to Spring Boot 4.1.x

The official Spring Boot 4.0 guide recommends stabilising on the latest 3.5.x version first, compiling, running tests and resolving all deprecations, as items marked as deprecated in 3.x may have been removed in 4.0. In real-world services, skipping this step mixes too many variables: previous technical debt, outdated dependencies, Jakarta and Jackson changes, broken tests and runtime differences.

The recommended path is:

  • Stabilize on the latest 3.5.x and leave build, tests and integration in green.
  • Run the migration to 4.0.x and fix compilation, startup and behaviour.
  • Consolidate in 4.1.x.

The key is to respect the order of the process. First reduce debt in 3.5.x and then address the platform change with fewer open variables.

System requirements and dependencies should also be reviewed. Spring Boot 4 requires Java 17 or higher, recommends using the most recent LTS (25 at this point), demands Kotlin 2.2+ if the project uses Kotlin, GraalVM 25+ if native images are built, and relies on Jakarta EE 11, with testing via JUnit 6. This directly impacts embedded servers and external containers.

When failures occur during migration, the affected layer should be identified first so that, if we seek documentation, we know which one to consult:

  • If the change is in “org.springframework.*”, it probably comes from Spring Framework 7.
  • If the change is in “org.springframework.Boot.*”, it probably comes from Spring Boot 4.
  • If it affects security, testing, Jackson or the embedded server, it may span multiple layers, so special attention should be paid to tracing its origin.

Migration failures can be classified into three distinct groups:

Compilation failures are the first group. They are annoying, but they are the easiest to tackle: the compiler tells you where to look. These include broken imports, removed APIs, and examples such as “@MockBean” being replaced by “@MockitoBean”.

The second group appears during startup. The application compiles, but fails on startup. Here, incompatible starters, outdated internal auto-configurations, dependencies that still use deprecated mechanisms and embedded servers not aligned with Servlet 6.1 appear.

The third group is the dangerous one: Silent failures. The application compiles, starts up and passes some of the tests, but its behaviour changes. This may affect JSON serialization, security rules, transactions, metrics or bean initialization. This is the type of failure that reaches production if the migration is validated only with a “green build”.

The migration should be managed as a process with clear exit criteria: compile, start up, validate contracts, review security—particularly for endpoints—and measure behaviour under load.

OpenRewrite Community’s recipe helps with the initial mechanical work, but it must be run on a controlled branch, the changes made must be reviewed, and it should be accompanied by contract, security and integration tests. To launch it, you can use the following command:

mvn -U org.openrewrite.maven:rewrite-maven-plugin:run
  --define rewrite.recipeArtifactCoordinates=org.openrewrite.recipe:rewrite-spring:RELEASE
  --define rewrite.activeRecipes=org.openrewrite.java.spring.boot4.UpgradeSpringBoot_4_0
  --define rewrite.exportDatatables=true


The UpgradeSpringBoot_4_0 recipe covers more than just a version upgrade. It includes migrations to Spring Framework 7, Spring Security 7, Spring Batch 6, Hibernate 7.1, Testcontainers 2, SpringDoc 3 and the modular starters of Spring Boot 4. It serves for mechanical work, although the generated diff requires checking. The migration is considered complete when there is evidence that the behaviour remains unchanged; a build and tests showing “green” only confirm part of it, as you must verify the application’s behaviour.

In addition, it is necessary to adjust some library names or imports that the OpenRewrite recipe has not modified, including:

org.apache.commons.lang3.StringUtils -> org.apache.commons.lang3.Strings
org.springframework.boot.actuate.health.* -> org.springframework.boot.health.contributor.*
com.fasterxml.jackson.* -> tools.jackson.*
java.nio.file.Paths -> java.nio.file.Path
org.springframework.lang.Nullable -> org.jspecify.annotations.Nullable
javax* -> jakarta*

In the case of “com.fasterxml.jackson”, not all imports should be changed at the same time: the annotations can be retained to avoid unnecessary changes in the DTOs. The import changes can be reviewed in the Jackson BOM reference.

In Spring Security 7, the change in path matching may alter authorization rules that previously seemed stable. In addition to checking startup, it is necessary to validate actual routes, rule order and differences between old and new patterns.

  • Change the engine to MVC/PathPattern
  • * “/” at the end may not behave the same
    • Current behaviour/ New:
// NOW (PathPattern - Spring Boot 4.1)
// "/api/orders" y "/api/orders/" son patrones DIFERENTES
@Bean
SecurityFilterChain afterConfig(HttpSecurity http) throws Exception {
    return http
        .authorizeHttpRequests(auth -> auth
            .requestMatchers("/api/orders").hasRole("USER")
            .anyRequest().authenticated()
        )
        .build();
}
// Behaviour CHANGES:
// GET /api/orders     ✓ Protected
// GET /api/orders/    ✘ NOT protected (PathPattern ve "/" as different)
  • Path variable matches the actual segment and not literal text
# Before:
- "/api/orders/{id}" podía tratarse como texto literal en algunos enfoques de matching.
- "/api/orders/" y "/api/orders" no siempre se comportaban igual.
# Now with MVC + PathPattern:
- "{id}" matches an actual segment of the route.
- The final slash may change the result of the match.
- Authorisation rules and security tests need to be re-validated.
  • Rule order is critical (a broad rule can “overlap” others)

This review serves to identify overly broad rules, paths that have undergone changes in interpretation, and discrepancies between the application’s historical behaviour and the current standard. The most reliable way to detect these differences is to run integration or E2E tests before and after the migration. If critical routes are already covered, any changes in authorization, CSRF or path matching will be easier to detect.

For renamed or removed properties, Spring Boot offers “spring-boot-properties-migrator”. This is a temporary aid: it prints diagnostics at startup and can adapt properties at runtime during the migration. It should be removed once the migration is complete.

<!-- A temporary module that updates application.properties/application.yml at runtime 
     also logs diagnostics on start-up -->
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-properties-migrator</artifactId>
    <scope>runtime</scope>
</dependency>
<!-- delete at the end of the migration -->

Spring Boot 4 introduces more specific starters. For example, “spring-boot-starter-web” remains the usual entry point for web applications, but certain technologies may require explicit starters. There is a temporary route with “spring-Boot-starter-classic” and “spring-Boot-starter-test-classic”, intended to recover a classpath similar to that of Boot 3 while fixing imports and dependencies. It should be treated as a migration bridge, not as a final destination.

Regarding the migration from “javax.*” to “jakarta.*” which has already begun in Spring Boot 3, Spring Framework 7 tightens this aspect further. An especially delicate case concerns lifecycle or injection annotations, which may compile but behave differently if legacy support remains on the classpath.

Internal autoconfigurations and custom starters must also be reviewed. The old pattern based on “spring.factories” must be migrated to the current “AutoConfiguration.imports” mechanism. If this point is left incomplete, the failure may manifest as a configuration that no longer loads or as a bean that disappears without an obvious error. The code below shows the route change that was being discussed.

# Before:
# FILE: META-INF/spring.factories
org.springframework.boot.autoconfigure.EnableAutoConfiguration=
com.edicom.repository.sync.AuthAutoConfiguration

# After:
# FILE: META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
com.edicom.repository.sync.AuthAutoConfiguration

There are further infrastructure changes that may appear minor but are not. “HttpHeaders” in Spring Framework 7 no longer behaves like a “MultiValueMap”, so utilities or filters that treat it as a map must migrate to the specific “headers” API. In projects with “null-checkers”, “JSpecify” replaces older “null-safety” annotations and may cause compilation errors or changes to “nullability”.

Spring Boot 4 separates persistence into new modules. A concrete example is “@EntityScan”, which shifts towards “org.springframework.boot.persistence.autoconfigure.EntityScan”. In multi-module applications, an old “import” may end up appearing as an issue with undetected entities when the real cause is a change in autoconfiguration.

Jackson 3

Jackson 3 is one of the most sensitive points of the migration. Although Jackson 2 can still be used as a temporary bridge, the migration to the new version must be planned because it may alter JSON contracts that external or internal consumers consider stable.

Jackson 2 can function as a temporary bridge. Treating it as the final destination, on the other hand, leaves technical debt with an expiry date.

The transition configuration lets you adjust the mapper’s behaviour without blocking the entire migration, provided that the actual contracts are validated afterwards. The following configuration shows an example of Jackson configuration where both versions coexist in an application.

spring:
  application:
    name: xxx
  jackson:
    default-property-inclusion: non_empty
    serialization:
      fail-on-empty-beans: false
    deserialization:
      fail-on-ignored-properties: false
      fail-on-unknown-properties: false
      fail-on-null-for-primitives: false
    datatype:
      datetime:
        write-dates-as-timestamps: false
        write-durations-as-timestamps: false
    find-and-add-modules: true
# config solo para jackson 3
---
spring:
  config:
    activate:
      on-profile: jackson3
  jackson:
    datatype:
      enum:
        read-unknown-enum-values-as-null: false

Spring Boot 4 incorporates explicit mechanisms for that transition. The “spring.Jackson.use-jackson2-defaults=true” property brings the mapper’s behaviour closer to Jackson 2’s default values, and the “spring-boot-jackson2” module helps buy time when the project is still unable to adopt Jackson 3. Both resources should be used as temporary support: they help reduce risk during migration, but do not eliminate the need to validate JSON contracts and schedule the definitive jump to Jackson 3.

The most critical aspect of the migration to Jackson 3 is the contract that other systems already consume. Dates, enums, nulls, custom modules, Optional, polymorphic types or error serialization can change without breaking compilation, but may break consumers, test snapshots or integrations that compare payloads byte by byte.

Another important detail: Spring Boot 4 autoconfigures format-specific “mappers”. For JSON, the relevant bean becomes “JsonMapper”; for XML, “XmlMapper”. If previously you could replace the behaviour by defining an “ObjectMapper”, it may no longer be sufficient. In advanced customizations, you should review “JsonMapperBuilderCustomizer”, registered modules and properties moved under “spring.jackson.json.*”.

Security, metrics and silent behaviour

Security merits extra attention. POST, PUT, PATCH and DELETE must be tested with real users, different roles and critical routes. Changes in CSRF, CORS or path matching can produce unexpected 403 errors or leave routes with different protection from what is expected.

After migration, real traffic must be forced and “/actuator/metrics” checked, along with correlated traces and logs; it is also advisable to review “liveness” and “readiness”. In Spring Boot 4, “health” groups are enabled by default. This is good for cloud environments, but it requires reviewing exactly what “ready” means in each application. A service can be alive but not ready to handle traffic if it has not yet initialized caches, routes, clients or critical dependencies.

In web MVC there is another detail: If HTTP converters are customized, “HttpMessageConverters” becomes deprecated and the configuration is better separated between client and server with specific customizers.

Declarative HTTP clients, gRPC and SSRF

With Spring Framework 7, declarative HTTP clients based on “@HttpExchange” reduce repetitive code and centralize the remote contract in an interface. This is useful when an integration has many endpoints, is reused across multiple services, or requires a definition that is easier to review.

The change is better understood by comparing two ways of modelling an HTTP integration: repeated imperative code versus an interface that consolidates contracts, routes and parameters.

In the previous approach, each method typically repeats request, response and URL-construction details. When an integration grows, that repetition makes it difficult to review the API’s actual contract.

Now the code can be simplified with “@HttpExchange”, which lets you define the base URL for an integration and complete each operation with annotations such as “@GetExchange”, “@PostExchange” or the corresponding method. The return type is declared in the method signature, and parameters such as “@PathVariable” allow the path to be constructed in a similar manner to a Spring REST controller.

With declarative clients, the interface becomes the visible contract of the integration. You can see what endpoints there are, what parameters they receive, and what they return without having to navigate through auxiliary code.

An example can be seen in the code below.

// BEFORE imperative code
@Service
class CustomerClient {
    private final RestClient restClient;
    CustomerClient(RestClient.Builder builder) {
        this.restClient = builder
            .baseUrl("https://customers.internal")
            .build();
    }
    CustomerDto findById(Long id) {
        return restClient.get()
            .uri("/customers/{id}", id)
            .retrieve()
            .body(CustomerDto.class);
    }
}
// AFTER
@HttpExchange("/customers")
interface CustomerClient {
    @GetExchange("/{id}")
    CustomerDto findById(@PathVariable Long id);
}

As can be seen, the code is now much cleaner and more readable. It leverages the interface to infer the contract—for example, the object returned by the function signature—rather than having to specify it manually.

Spring Boot 4.1 also reinforces support for “gRPC”. REST remains excellent for public APIs and broad consumption. Meanwhile, “gRPC” fits better for internal communication, strongly typed contracts, streaming, or low latency between services controlled by the same organization.

SSRF must also be taken into account. It appears if the backend opens connections from URLs controlled by user input or external data. In Spring Boot 4.1, InetAddressFilter allows blocking of ranges or destinations in configured HTTP clients; defence still requires an allowlist, controlled DNS, timeouts, and negative testing against localhost, private networks and cloud metadata.

In an application that consumes URLs received from external sources, SSRF protection must determine which destinations are valid before opening the connection. The visual example contrasts a direct call with one filtered by an allowlist, range validation and execution limits.

The practical difference is that the application ceases to act as an open proxy. Only expected destinations are allowed, unauthorized internal networks are blocked, and timeouts are added to prevent malicious input from degrading the service.

That approach turns SSRF validation into an explicit decision before exiting to the network: permitted destination, blocked ranges, controlled DNS and execution limits.

The real protection combines host allowlisting, private range blocking, controlled DNS, size limits, timeouts and network policies. The framework reduces the attack surface; the application must specify which destinations it accepts and under what conditions.

In testing, migration matters because it changes how mocks, test clients and Spring contexts are prepared. If these changes are treated as simple renames, it is easy to maintain green tests that no longer cover the same behaviour.

The replacement of “@MockBean” with “@MockitoBean” should be reviewed alongside the lifecycle of the test context, because it can affect which beans are substituted and when they are initialized.

// BEFORE MockMvc with @SpringBootTest
@SpringBootTest
class UserControllerIT {
    @Autowired
    MockMvc mockMvc;
}
// AFTER
@SpringBootTest
@AutoConfigureMockMvc
class UserControllerIT {
    @Autowired
    MockMvc mockMvc;
}

MockMvc should no longer be assumed to be available just because you use “@SpringBootTest”. If a test needs it, it should be declared explicitly with “@AutoConfigureMockMvc”.

In tests that start the server, “TestRestTemplate” should also be configured explicitly with “@SpringBootTest” and “@AutoConfigureTestRestTemplate”. The intention is for the test to declare what infrastructure it needs, rather than relying on side effects of the context.

Important APIs to “highlight” for migration

The following table shows a summary of some of the APIs that are “deprecated” and are worth highlighting so that, if we use them or would like to, we can review their official migration documentation.

Deprecated in 7.0Migrate to
Jackson 2Jackson 3
AntPathMatcher for request mappingsPathPattern
PathMatcher in Spring MVCPathPattern
RestTemplateRestClient
JUnit 4JUnit 6
<mvc:*> XML namespaceJava config

Criteria for considering the migration complete

Each item on the following checklist should be validated against a live service: which endpoint or contract is affected, which test covers it, which metric confirms that behaviour has not changed, and what rollback plan there is in case of regression.

The final checklist brings together the points where a migration may fail, even though it compiles: JSON contracts, security rules, configuration, internal auto-configurations, observability and integration tests.

After checking the immediate risks of Spring Boot 4.1.x, you should monitor the JDK with operational judgement: startup, memory, concurrency, security and observability.

Once the Spring Boot migration is complete, the next decision axis is the JVM on which it runs: what changes in Java 26/27 and how much of that affects operational costs today. In the following points of this article, additional Java changes in future versions are discussed.

Java and OpenJDK after 25: what awaits us

After Java 25, the conversation stops focusing only on new language APIs. For backend, what matters is how the JVM evolves: startup, warmup, per-object memory, concurrency, observability and TLS stack security.

Java 26 and Java 27 focus on which costs the JVM wants to reduce, which security areas are being strengthened, and which parts of the runtime may change the way services operate in the coming cycles.

Java 26 was published in March 2026. It includes, among other JEPs, AOT Object Caching with any GC, HTTP/3 for the HTTP Client API, and improvements to G1.

  • HTTP/3 for the HTTP Client API.
  • Ahead-of-Time Object Caching with any “Garbage Collector”.
  • Performance improvements in G1 (the JVM default Garbage Collector).
  • Evolution of the concurrency model and language without yet treating them as a stable foundation.
  • Platform cleanup and security: definitive removal of the Applet API, PEM.

Java 27 is scheduled for September 2026. Any feature list should be read as a plan subject to the final status of JEPs and official notes.

  • Default Compact Object Headers, the most visible materialization of OpenJDK’s project Lilliput: lower per-Object cost and a potentially more efficient JVM in applications with millions of small objects.
  • G1 as the default garbage collector in all environments, simplifying expected JVM behaviour and avoiding differences between configurations.
  • Post-Quantum Hybrid Key Exchange for TLS 1.3, relevant for secure communications, HTTP clients, mTLS, and compliance requirements.
  • JFR In-Process Data Redaction, useful for observability in environments where traces must not expose sensitive data.
  • Structured Concurrency, Lazy Constants, Vector APIs and patterns using primitive types continue to advance in preview or incubator status; they are directional signals, not an invitation to deploy everything into production without reviewing flags and support.

OpenJDK organizes some of its development lines as “Projects”, technical efforts that mature before emerging as visible changes in the JDK. Project Lilliput is a good example: it works on reducing the cost of object headers so that applications with many small objects can use less memory without changing their programming model.

Project Leyden aims to improve startup, warmup and execution predictability. The aim is not just for an application to start quickly, but to reduce the time until the service is truly ready to receive traffic. In cloud environments such as Kubernetes, this is particularly relevant.

Project Lilliput operates on more compact object headers. Each Java object has internal metadata in addition to its fields. In applications with millions of small objects, this cost adds up: DTOs, entities, events, maps, lists, wrappers, serialization objects or intermediate structures created by frameworks.

Lilliput’s value lies in enabling the JVM to execute the same semantics with lower memory overhead; developers do not need to change their code overnight to benefit from this approach.

Project Valhalla aims for denser data models using value objects or “primitive classes”. The simplified idea is to be able to represent certain data as values, with less cost in terms of identity, indirection and reference. This can affect domains with many small structures.

There is also movement in security. Java is starting to prepare for post-quantum cryptography and hybrid exchanges in TLS. For many teams, it will not be an API they touch directly, but it will affect services that depend on the JDK TLS stack, HTTP clients, internal libraries, mTLS, compliance or inter-service communications.

The practical reading is straightforward: Leyden affects startup and warmup; Lilliput, the cost per object; Valhalla, denser data models; and JDK security lines, the TLS stack and compliance requirements. Not all require immediate action, but it is important to know which ones could influence platform decisions in the medium term.

The following timeline shows a summary of the Java versions highlighted in this article.

Conclusion

Migration is considered complete when there is evidence that the behaviour remains unchanged, not merely when the project compiles and tests are passed. Compiling confirms that the code is syntactically valid; it does not confirm that JSON contracts remain unchanged, that authorization rules protect what they should, or that critical endpoints respond identically under real-world traffic.

The path covered in this document—stabilising in Spring Boot 3.5, jumping platform in 4.0 and consolidating in 4.1—only makes sense if at each stage it is explicitly validated what could break silently.

Spring Boot 4 and Java 25+ represent a genuine opportunity for modernization: improved default security (SSRF, Actuator management), performance and startup enhancements inherited from the latest Java versions, and a cleaner development model with declarative HTTP clients and native support for gRPC. But that opportunity only materialises if it is treated as what it is: a full platform migration, not merely a version bump of another dependency.

Official references and blogs of interest