🤔 Want to upgrade Java, Spring Boot versions is a methodical way
There is a platform for that!
Moderne’s OpenRewrite platform helps with managing complexities in upgrading your Java based projects
Some common use cases include:
- Upgrading to Java 17
- Upgrading Spring Boot 2 to Spring Boot 3
Why a tool?
Knowing the API changes in libraries for every dependency is difficult. Also, a lot of time can be wasted in a particular solution that does not work well with a particular dependency.
How does it work?
You can import custom recipes as Maven/Gradle task and run them.
For example, you want to migrate from JUnit 4 to JUnit 5, you can import a recipe for it in Gradle like this:
activeRecipe("org.openrewrite.java.testing.junit5.JUnit5BestPractices")activeRecipe("org.openrewrite.java.testing.junit5.JUnit5BestPractices")activeRecipe("org.openrewrite.java.testing.junit5.JUnit5BestPractices")
Enter fullscreen mode Exit fullscreen mode
And run the gradle task:
gradlew rewriteRungradlew rewriteRungradlew rewriteRun
Enter fullscreen mode Exit fullscreen mode
Since these recipes are chainable, you can add steps to make code changes incrementally.
Other features include:
- Writing your own custom recipes for your use-case
- Dashboard to track the recipes done in your project to track your level of completion of version migration.
Resources:
- Moderne’s site: https://www.moderne.io
- OpenRewrite recipes: https://docs.openrewrite.org/
暂无评论内容