This is an automated email from the ASF dual-hosted git repository. jiriondrusek pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel-upgrade-recipes.git
The following commit(s) were added to refs/heads/main by this push: new ae9a979 Prepared empty recipes/test classes for upgrade to Camel 4.13 ae9a979 is described below commit ae9a9794370a1d959cf82f6c8db54d2335c06fe8 Author: Jiri Ondrusek <ondrusek.j...@gmail.com> AuthorDate: Mon Jun 9 15:08:11 2025 +0200 Prepared empty recipes/test classes for upgrade to Camel 4.13 --- .../src/main/resources/META-INF/rewrite/4.13.yaml | 25 +++++++++++ .../src/main/resources/META-INF/rewrite/4.13.yaml | 40 ++++++++++++++++++ .../org/apache/camel/upgrade/CamelTestUtil.java | 3 +- .../apache/camel/upgrade/CamelUpdate413Test.java | 48 ++++++++++++++++++++++ 4 files changed, 115 insertions(+), 1 deletion(-) diff --git a/camel-spring-boot-upgrade-recipes/src/main/resources/META-INF/rewrite/4.13.yaml b/camel-spring-boot-upgrade-recipes/src/main/resources/META-INF/rewrite/4.13.yaml new file mode 100644 index 0000000..31ecb50 --- /dev/null +++ b/camel-spring-boot-upgrade-recipes/src/main/resources/META-INF/rewrite/4.13.yaml @@ -0,0 +1,25 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +--- +type: specs.openrewrite.org/v1beta/recipe +name: org.apache.camel.upgrade.camel413.CamelSpringBootMigrationRecipe +displayName: Migrates Camel Spring Boot applications to Camel Spring Boot 4.12 +description: Migrates Camel Spring Boot applications to Camel Spring Boot 4.12 +recipeList: + - org.apache.camel.upgrade.camel412.CamelSpringBootMigrationRecipe + - org.apache.camel.upgrade.camel413.CamelMigrationRecipe +# - any new CSB recipe for C4.13 goes here and to the latest.yaml \ No newline at end of file diff --git a/camel-upgrade-recipes/src/main/resources/META-INF/rewrite/4.13.yaml b/camel-upgrade-recipes/src/main/resources/META-INF/rewrite/4.13.yaml new file mode 100644 index 0000000..cdd6554 --- /dev/null +++ b/camel-upgrade-recipes/src/main/resources/META-INF/rewrite/4.13.yaml @@ -0,0 +1,40 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +##### +# Rules coming from https://camel.apache.org/manual/camel-4x-upgrade-guide-4_112.html +##### + +##### +# Update the Camel project from 4.11 to 4.12 +##### +--- +type: specs.openrewrite.org/v1beta/recipe +name: org.apache.camel.upgrade.camel413.CamelMigrationRecipe +displayName: Migrates `camel 4.12` application to `camel 4.13` +description: Migrates `camel 4.12` application to `camel 4.13`. +recipeList: + - org.apache.camel.upgrade.camel413.emptyRecipe +--- +type: specs.openrewrite.org/v1beta/recipe +name: org.apache.camel.upgrade.camel413.emptyRecipe +displayName: The package scan classes has moved from camel-base-engine to camel-support - java +description: The package scan classes has moved from camel-base-engine to camel-support JAR and moved to a new package - java. +recipeList: + - org.openrewrite.java.ChangeType: + oldFullyQualifiedTypeName: fake.Class + newFullyQualifiedTypeName: fake.Class \ No newline at end of file diff --git a/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelTestUtil.java b/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelTestUtil.java index 11928ee..6f83036 100644 --- a/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelTestUtil.java +++ b/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelTestUtil.java @@ -48,7 +48,8 @@ public class CamelTestUtil { v4_9(4, 9, 0), v4_10(4, 10, 0), v4_11(4, 11, 0), - v4_12(4, 12, 0); + v4_12(4, 12, 0), + v4_13(4, 13, 0); private int major; private int minor; diff --git a/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate413Test.java b/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate413Test.java new file mode 100644 index 0000000..6bbcc01 --- /dev/null +++ b/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate413Test.java @@ -0,0 +1,48 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.upgrade; + +import org.junit.jupiter.api.Test; +import org.openrewrite.test.RecipeSpec; +import org.openrewrite.test.RewriteTest; +import org.openrewrite.test.TypeValidation; + +import static org.openrewrite.java.Assertions.java; + +public class CamelUpdate413Test implements RewriteTest { + + @Override + public void defaults(RecipeSpec spec) { + CamelTestUtil.recipe(spec, CamelTestUtil.CamelVersion.v4_13) + .parser(CamelTestUtil.parserFromClasspath(CamelTestUtil.CamelVersion.v4_12, "camel-base")) + .typeValidationOptions(TypeValidation.none()); + } + + /** + * Empty placeholder + */ + @Test + public void fakeTest() { + //language=java + rewriteRun(java( + """ + public class Fake { + } + """)); + } + +}