We all are aware that...
3.0is coming ❕
Since a few months as part of our pipeline's migration from onPremise to Github.com process we have been prototyping on Spring Native and invest on maintenance by upgrading :
- Our dependencies (let Dependabot PRs ⛆ 😱 ), making us upgrade all to
2.6.7, then more recently
- Our runtime from
Java 17... from the dev side up to the server runtime
That was a big work to achieve but offered us the opportunity to improve our testing strategies (less code for more coverage), dependencies cleanup/removal to make native easier in a near future.
Notice that this investment made it possible to achieve
RUNtasks in a much more comfortable on a continuous pace and less time consuming way... while making it possible to upgrade the middlewares we rely on.
So we chose the following straightforward strategy :
We did migrate our Elastic instance to Elastic 7... and wait to Spring Boot 3, based on Spring 6 and Java 17.
Find below the compatibility matrix (so you don't have to look for it 😓) :
In the mean time we also did prepare traditional (non native) docker images that embeds a secured Java 17 runtime, see below for more :
Fortunately Spring tweeted a dedicated post on this topic :
According to the blog post, here are the things you can do to get ready.
In our team, this will be used as a checklist to get ready to migrate as clean as possible :
"Spring Boot 3.0 will require Java 17."
Hence it makes it possible to use Records.
Also here is Spring advice :
"We highly recommend that you upgrade your JDK today if at all possible."
Spring will provide a migration guide to Spring Boot 3...
"but it will assume that you’re migrating from Spring Boot 2.7 and not an earlier version."
We also applied the following migration strategy, following SB upgrades on a continuous way (so we finally could drastically reduce our technical debt):
If you’re upgrading from Spring Boot 2.5 or earlier, we don’t recommend skipping releases.** It’s often easier to upgrade in steps** (e.g. 2.5 → 2.6 → 2.7) rather than trying to upgrade directly from 2.5 → 2.7.
Spring Boot 3.0 will remove all deprecated code, so we recommend that you check your existing code is not relying on any deprecated methods. It’s worth considering using the
-WerrorJava compiler option to fail your build if deprecation warnings are reported.
The legacy processing support will not be coming to Spring Boot 3.0 so you should check that your project doesn’t set
we recommend using the
PathPatternParserif at all possible since it provides better performance.
Also see the full blog post for more about Third-party Projects Have Jakarta EE 9 Compatible Releases and Third-party Projects have Updated Spring Compatible Releases