<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>OpenRewrite on foojay.io - Friends of OpenJDK</title><link>https://foojayio.github.io/website/today/category/openrewrite/</link><description>Recent content in OpenRewrite on foojay.io - Friends of OpenJDK</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Thu, 13 Nov 2025 09:09:17 +0000</lastBuildDate><atom:link href="https://foojayio.github.io/website/today/category/openrewrite/index.xml" rel="self" type="application/rss+xml"/><item><title>Testing an OpenRewrite Recipe</title><link>https://foojayio.github.io/website/today/testing-an-openrewrite-recipe/</link><pubDate>Mon, 14 Jul 2025 09:43:52 +0000</pubDate><guid>https://foojayio.github.io/website/today/testing-an-openrewrite-recipe/</guid><description>&lt;p&gt;For the last two weeks, I&amp;rsquo;ve kicked the tires of OpenRewrite.&lt;/p&gt;
&lt;p&gt;At first, I created a &lt;a href="https://blog.frankel.ch/openrewrite-recipes/1/" target="_blank" rel="noopener noreferrer"&gt;recipe to move Kotlin source files&lt;/a&gt;
 as per the official recommendations with a set package name.&lt;/p&gt;
&lt;p&gt;I then improved the &lt;a href="https://blog.frankel.ch/openrewrite-recipes/2/" target="_blank" rel="noopener noreferrer"&gt;recipe to compute the root automatically&lt;/a&gt;
. In both versions, I thoroughly tested the recipe.&lt;/p&gt;
&lt;p&gt;However, my testing approach was wrong. In this post, I want to describe my mistakes, and how I fixed them.&lt;/p&gt;</description></item><item><title>Authoring an OpenRewrite Recipe</title><link>https://foojayio.github.io/website/today/authoring-an-openrewrite-recipe/</link><pubDate>Mon, 09 Jun 2025 17:22:13 +0000</pubDate><guid>https://foojayio.github.io/website/today/authoring-an-openrewrite-recipe/</guid><description>&lt;p&gt;I&amp;rsquo;ve been eying OpenRewrite for some time, but I haven&amp;rsquo;t had time to play with it yet. In case you never heard about OpenRewrite, OpenRewrite takes care of refactoring your codebase to newer language, framework, and paradigm versions.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;OpenRewrite is an open-source automated refactoring ecosystem for source code, enabling developers to effectively eliminate technical debt within their repositories.&lt;/p&gt;
&lt;p&gt;It consists of an auto-refactoring engine that runs prepackaged, open-source refactoring recipes for common framework migrations, security fixes, and stylistic consistency tasks &amp;ndash; reducing your coding effort from hours or days to minutes. Build tool plugins like the OpenRewrite Gradle plugin and the OpenRewrite Maven plugin help you run these recipes on one repository at a time.&lt;/p&gt;</description></item><item><title>Foojay Podcast #63: How do we keep your Java applications up to date and secure?</title><link>https://foojayio.github.io/website/today/foojay-podcast-63/</link><pubDate>Mon, 16 Dec 2024 12:41:10 +0000</pubDate><guid>https://foojayio.github.io/website/today/foojay-podcast-63/</guid><description>&lt;h2 id="h2-0-last-month-i-published-a-foojay-article-about-the-risks-in-systems-that-are-stuck-on-old-or-outdated-java-versions-and-got-a-lot-of-feedback-from-developers-most-of-them-want-to-move-on-but-get-stuck-on-management-decisions-outdated-production-environments-or-one-of-the-many-other-reasons-that-keep-systems-stuck-on-old-java-versions-and-dependencies"&gt;Last month, I published a Foojay article about &lt;a href="https://foojayio.github.io/website/today/why-java-8-is-a-ticking-time-bomb-hiding-within-your-organization/"&gt;the risks in systems that are stuck on old or outdated Java versions&lt;/a&gt;
 and got &lt;a href="https://foojayio.github.io/website/today/how-organizations-became-stuck-on-outdated-java-versions/"&gt;a lot of feedback from developers&lt;/a&gt;
. Most of them want to move on but get stuck on management decisions, outdated production environments, or one of the many other reasons that keep systems stuck on old Java versions and dependencies.&lt;/h2&gt;
&lt;p&gt;Do you want to bring your system from Java 8 to 23? Did you know that Java 17 already has 13 security releases? And that you can use tools like OpenRewrite to help you update your code?&lt;/p&gt;</description></item><item><title>Foojay Podcast #53: JCON Report, Part 5 – CQRS, JOOQ, GraphQL, API, Vaadin, OpenRewrite, ErrorProne, Gateways, Proxies,...</title><link>https://foojayio.github.io/website/today/foojay-podcast-53/</link><pubDate>Mon, 17 Jun 2024 09:24:52 +0000</pubDate><guid>https://foojayio.github.io/website/today/foojay-podcast-53/</guid><description>&lt;p&gt;This is the final part of the JCON interviews. Did I save the best for last? It&amp;rsquo;s up to you to decide&amp;hellip;&lt;/p&gt;
&lt;p&gt;In this episode you&amp;rsquo;ll hear Simon Martinelli, Nicolas Fränkel, Marcus Hellberg, Rick Ossendrijver, and Abdel Sghiouar.&lt;/p&gt;
&lt;p&gt;We talked about a bunch of topics like evolving your APIs, GraphQL, Java versus Kotlin versus Rust, Vaadin, AI and ChatGPT, OpenRewrite, ErrorProne, Infrastructure, and a lot more.&lt;/p&gt;
&lt;h2 id="h2-0-video"&gt;Video&lt;/h2&gt;
&lt;div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"&gt;
			&lt;iframe allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share; fullscreen" loading="eager" referrerpolicy="strict-origin-when-cross-origin" src="https://www.youtube.com/embed/6ops5sU_UiY?autoplay=0&amp;amp;controls=1&amp;amp;end=0&amp;amp;loop=0&amp;amp;mute=0&amp;amp;start=0" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" title="YouTube video"&gt;&lt;/iframe&gt;
		&lt;/div&gt;

&lt;h2 id="h2-1-podcast-apps"&gt;Podcast Apps&lt;/h2&gt;
&lt;p&gt;You can listen and subscribe to the Foojay Podcast on:&lt;/p&gt;</description></item><item><title>Migrate to Spring Boot 3.2 with OpenRewrite</title><link>https://foojayio.github.io/website/today/openrewrite-migrate-to-spring-boot-3-2/</link><pubDate>Tue, 06 Feb 2024 08:17:07 +0000</pubDate><guid>https://foojayio.github.io/website/today/openrewrite-migrate-to-spring-boot-3-2/</guid><description>&lt;p&gt;&lt;strong&gt;As a developer, we frequently face the challenges of migrating to newer versions of frameworks and refactoring code. However, we can effortlessly achieve these tasks with the assistance of &lt;a href="https://docs.openrewrite.org/" target="_blank" rel="noopener noreferrer"&gt;OpenRewrite&lt;/a&gt;
. OpenRewrite provides a stack of recipes specifically designed for migration purposes. By utilizing the appropriate recipes and integrating with the rewrite plugin, we can effectively migrate our code.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Two months ago, the Spring Boot 3.2 version released, bringing numerous changes to the framework. If you are involved in multiple projects and require migrating to the latest version, developers may find manually updating all the code repositories with the necessary upgrade changes a challenging task.&lt;/p&gt;</description></item><item><title>OpenRewrite: Automatic Code Refactoring and More - Part 2</title><link>https://foojayio.github.io/website/today/openrewrite-automatic-code-refactoring-and-maintenance-part-2/</link><pubDate>Thu, 14 Sep 2023 06:56:36 +0000</pubDate><guid>https://foojayio.github.io/website/today/openrewrite-automatic-code-refactoring-and-maintenance-part-2/</guid><description>&lt;p&gt;In the &lt;a href="https://foojayio.github.io/website/today/openrewrite-automatic-code-refactoring-and-maintenance/"&gt;previous article&lt;/a&gt;
, we outlined the significance of the OpenRewrite Library and its integration at an elevated level.&lt;/p&gt;
&lt;p&gt;This article explains how to improve, refactor, and move a Spring Boot application with OpenRewrite.&lt;br&gt;
&lt;img src="https://foojayio.github.io/website/today/openrewrite-automatic-code-refactoring-and-maintenance-part-2/OpenRewrite.gif" alt="Open Rewrite" loading="lazy"&gt;
&lt;/p&gt;
&lt;p&gt;Source: OpenReWrite{#caption-attachment-102151}&lt;/p&gt;
&lt;p&gt;Before proceeding, we shall understand the various goals in the &lt;strong&gt;Maven or Gradle plugin&lt;/strong&gt; &lt;strong&gt;configuration&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;The &lt;strong&gt;OpenRewrite Maven&lt;/strong&gt; offers the following goals:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;mvn rewrite:cyclonedx&lt;/code&gt; - This will generate a &lt;a href="https://cyclonedx.org/" target="_blank" rel="noopener noreferrer"&gt;Cyclonedx&lt;/a&gt;
 bill of materials describing the application/project dependencies, including &lt;a href="https://en.wikipedia.org/wiki/Transitive_dependency" target="_blank" rel="noopener noreferrer"&gt;transitive dependencies&lt;/a&gt;
.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mvn rewrite:discover&lt;/code&gt; - Generate a report detailing the recipes that are currently available within the classpath.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mvn rewrite:dryRun&lt;/code&gt; - This precautionary command will generate a set of differences solely for the modifications made within the &lt;code&gt;/target/rewrite&lt;/code&gt; directory, which will be saved in the &lt;code&gt;rewrite.patch&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mvn rewrite:dryRunNoFork&lt;/code&gt; - This precautionary command will generate a set of differences solely for the modifications made within the &lt;code&gt;/target/rewrite&lt;/code&gt; directory, which will be saved in the &lt;code&gt;rewrite.patch&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mvn rewrite:run&lt;/code&gt;- This command runs the configured recipes and applies the changes locally.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;mvn rewrite:runNoFork&lt;/code&gt; -This command runs the configured recipes and applies the changes locally.&lt;/li&gt;
&lt;li&gt;For &lt;code&gt;runForFork:&lt;/code&gt; This different way of doing things doesn&amp;rsquo;t split up the Maven process and could work better when using Rewrite with other Maven tasks in a continuous integration (CI) system.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The &lt;strong&gt;OpenRewrite Gradle&lt;/strong&gt; offers the following goals:&lt;/p&gt;</description></item><item><title>OpenRewrite: Automatic Code Refactoring and Maintenance</title><link>https://foojayio.github.io/website/today/openrewrite-automatic-code-refactoring-and-maintenance/</link><pubDate>Tue, 05 Sep 2023 17:05:06 +0000</pubDate><guid>https://foojayio.github.io/website/today/openrewrite-automatic-code-refactoring-and-maintenance/</guid><description>&lt;p&gt;As software engineers and architects, we often face the challenge of upgrading dependencies, security patches, and framework upgrades to the latest versions. Enterprise organizations often have legacy code developed and maintained for a long time.&lt;/p&gt;
&lt;p&gt;Updating dependency versions in the build file in many build files in the software projects, and implementing large framework upgrades can be a daunting task for developers, who must manually inspect and modify class files, properties, and the build files such as &lt;code&gt;pom.xml&lt;/code&gt; or &lt;code&gt;build.gradle&lt;/code&gt; or any other build files.&lt;/p&gt;</description></item><item><title>OpenRewrite: we all grow older, but do our projects really have to?</title><link>https://foojayio.github.io/website/today/we-all-grow-older-but-do-our-projects-really-have-to-openrewrite/</link><pubDate>Tue, 08 Aug 2023 09:24:44 +0000</pubDate><guid>https://foojayio.github.io/website/today/we-all-grow-older-but-do-our-projects-really-have-to-openrewrite/</guid><description>&lt;p&gt;&lt;strong&gt;We have all likely worked on a project, that has grown quite &amp;ldquo;mature&amp;rdquo; over time, who knows we might even have forgotten to keep our dependencies up to date? Mayhap we finally got the green light to move from JDK 8 to 17?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;This will quite likely entail a lot of library updates, and maybe some interesting changes (cough javax =&amp;gt; jakarta).&lt;/p&gt;
&lt;p&gt;This is where a rewrite tool like OpenRewrite can come in handy, and I would like to walk through some of the options of this tool in this article.&lt;/p&gt;</description></item><item><title>Upgrade to Jakarta EE 10 and GlassFish 7: Easier Than You Think!</title><link>https://foojayio.github.io/website/today/how-to-upgrade-to-jakarta-ee-10-and-glassfish-7-its-much-easier-than-you-think/</link><pubDate>Tue, 27 Jun 2023 07:29:48 +0000</pubDate><guid>https://foojayio.github.io/website/today/how-to-upgrade-to-jakarta-ee-10-and-glassfish-7-its-much-easier-than-you-think/</guid><description>&lt;p&gt;Upgrading to Jakarta EE 10 from an older version of Jakarta EE or Java EE can be a bit tricky and may require some extra attention to detail. But don&amp;rsquo;t worry, we&amp;rsquo;ve got you covered!&lt;/p&gt;
&lt;p&gt;In this series of articles, we&amp;rsquo;ll explain everything you need to know before upgrading to Jakarta EE 10 and guide you to complete the upgrade successfully and in almost no time.&lt;/p&gt;
&lt;h2 id="h2-0-types-of-challenges"&gt;Types of challenges&lt;/h2&gt;
&lt;p&gt;The challenges with upgrading to Jakarta EE 10 or to Eclipse GlassFish 7 fall into these 3 main categories:&lt;/p&gt;</description></item><item><title>Foojay Podcast #19: Working Free For Fun Brings Fame &amp; Fortune</title><link>https://foojayio.github.io/website/today/foojay-podcast-19/</link><pubDate>Mon, 17 Apr 2023 12:35:51 +0000</pubDate><guid>https://foojayio.github.io/website/today/foojay-podcast-19/</guid><description>&lt;p&gt;Many developers spend a lot of their time on side projects. It&amp;rsquo;s an opportunity to learn new techniques and get involved in communities.&lt;/p&gt;
&lt;p&gt;But sometimes it can also lead to a new job.&lt;/p&gt;
&lt;p&gt;Or even starting a business based on such a project.&lt;/p&gt;
&lt;p&gt;Today we are talking to people who achieved such a transition and became famous and rich, or at least some of each&amp;hellip;&lt;/p&gt;
&lt;div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"&gt;
			&lt;iframe allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share; fullscreen" loading="eager" referrerpolicy="strict-origin-when-cross-origin" src="https://www.youtube.com/embed/FDOFRTj1UVI?autoplay=0&amp;amp;controls=1&amp;amp;end=0&amp;amp;loop=0&amp;amp;mute=0&amp;amp;start=0" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" title="YouTube video"&gt;&lt;/iframe&gt;
		&lt;/div&gt;

&lt;h2 id="h2-1--odcast-pps"&gt;Podcast Apps&lt;/h2&gt;
&lt;p&gt;You can listen and subscribe to the Foojay Podcast on:&lt;/p&gt;</description></item></channel></rss>