You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by tc...@apache.org on 2026/03/23 16:42:10 UTC
(camel-upgrade-recipes) branch 419updates created (now e78e08c)
This is an automated email from the ASF dual-hosted git repository.
tcunning pushed a change to branch 419updates
in repository https://gitbox.apache.org/repos/asf/camel-upgrade-recipes.git
at e78e08c Remove MDC logging migration
This branch includes the following new commits:
new e78e08c Remove MDC logging migration
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(camel-upgrade-recipes) 01/01: Remove MDC logging migration
Posted by tc...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
tcunning pushed a commit to branch 419updates
in repository https://gitbox.apache.org/repos/asf/camel-upgrade-recipes.git
commit e78e08c18344a19225b9b34f9fd77adff5e89734
Author: Tom Cunningham <tc...@redhat.com>
AuthorDate: Mon Mar 23 09:27:08 2026 -0400
Remove MDC logging migration
---
.../src/main/resources/META-INF/rewrite/4.19.yaml | 13 ----
.../apache/camel/upgrade/CamelUpdate419Test.java | 73 ----------------------
2 files changed, 86 deletions(-)
diff --git a/camel-upgrade-recipes/src/main/resources/META-INF/rewrite/4.19.yaml b/camel-upgrade-recipes/src/main/resources/META-INF/rewrite/4.19.yaml
index d19e0db..fcd9ee4 100644
--- a/camel-upgrade-recipes/src/main/resources/META-INF/rewrite/4.19.yaml
+++ b/camel-upgrade-recipes/src/main/resources/META-INF/rewrite/4.19.yaml
@@ -45,21 +45,8 @@ recipeList:
key: camel.version
newValue: @camel-latest-version@
# Then run API migrations
- - org.apache.camel.upgrade.camel419.migrateMdcLogging
- org.apache.camel.upgrade.camel419.migrateGroovyXml
---
-# https://camel.apache.org/manual/camel-4x-upgrade-guide-4_19.html#_mdc_older_logic_deprecation
-# Migrate from deprecated useMdcLogging property to camel-mdc component
-type: specs.openrewrite.org/v1beta/recipe
-name: org.apache.camel.upgrade.camel419.migrateMdcLogging
-displayName: Remove deprecated MDC logging property
-description: The older logic used for MDC (enabled via camel.main.useMdcLogging = true) is deprecated in favor of camel-mdc component. This recipe removes the deprecated property. If you were using MDC logging, manually add the camel-mdc dependency.
-recipeList:
- - org.openrewrite.properties.DeleteProperty:
- propertyKey: camel.main.useMdcLogging
- - org.openrewrite.yaml.DeleteProperty:
- propertyKey: $.camel.main.useMdcLogging
----
# https://camel.apache.org/manual/camel-4x-upgrade-guide-4_19.html#_camel_groovy_xml
# Migrate camel-groovy-xml to camel-groovy
type: specs.openrewrite.org/v1beta/recipe
diff --git a/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate419Test.java b/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate419Test.java
index 455d963..1467fd5 100644
--- a/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate419Test.java
+++ b/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate419Test.java
@@ -16,15 +16,10 @@
*/
package org.apache.camel.upgrade;
-import org.junit.jupiter.api.Test;
-import org.openrewrite.DocumentExample;
import org.openrewrite.test.RecipeSpec;
import org.openrewrite.test.RewriteTest;
import org.openrewrite.test.TypeValidation;
-import static org.openrewrite.maven.Assertions.pomXml;
-import static org.openrewrite.properties.Assertions.properties;
-
//class has to stay public, because test is extended in project quarkus-updates
public class CamelUpdate419Test implements RewriteTest {
@@ -35,72 +30,4 @@ public class CamelUpdate419Test implements RewriteTest {
"camel-core-model", "camel-api"))
.typeValidationOptions(TypeValidation.none());
}
-
- /**
- * <a href="https://camel.apache.org/manual/camel-4x-upgrade-guide-4_19.html#_mdc_older_logic_deprecation">MDC Logging migration</a>
- */
- @DocumentExample
- @Test
- void migrateMdcLogging() {
- //language=xml
- rewriteRun(
- pomXml(
- """
- <project>
- <modelVersion>4.0.0</modelVersion>
-
- <artifactId>test</artifactId>
- <groupId>org.apache.camel.test</groupId>
- <version>1.0.0</version>
-
- <properties>
- <camel.version>4.18.0</camel.version>
- </properties>
-
- <dependencies>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-core</artifactId>
- <version>${camel.version}</version>
- </dependency>
- </dependencies>
- </project>
- """,
- """
- <project>
- <modelVersion>4.0.0</modelVersion>
-
- <artifactId>test</artifactId>
- <groupId>org.apache.camel.test</groupId>
- <version>1.0.0</version>
-
- <properties>
- <camel.version>4.18.0</camel.version>
- </properties>
-
- <dependencies>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-core</artifactId>
- <version>${camel.version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-mdc</artifactId>
- <version>${camel.version}</version>
- </dependency>
- </dependencies>
- </project>
- """
- ),
- properties(
- """
- camel.main.useMdcLogging=true
- """,
- """
- """,
- spec -> spec.path("application.properties")
- )
- );
- }
}