Skip to content

Commit 5bb1cd8

Browse files
committed
Add Boot 3.5 upgrade
1 parent 4e110a1 commit 5bb1cd8

File tree

5 files changed

+143
-2
lines changed

5 files changed

+143
-2
lines changed

eclipse-language-servers/org.springframework.tooling.boot.ls/src/org/springframework/tooling/boot/ls/prefs/PrefsInitializer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ public void initializeDefaultPreferences() {
5151
"org.openrewrite.java.testing.junit5.JUnit5BestPractices",
5252
"org.openrewrite.java.testing.junit5.JUnit4to5Migration",
5353
"org.openrewrite.java.spring.boot2.UpgradeSpringBoot_2_7",
54-
"org.openrewrite.java.spring.boot3.UpgradeSpringBoot_3_3",
5554
"org.springframework.ide.vscode.rewrite.boot3.UpgradeSpringBoot_3_4",
55+
"org.springframework.ide.vscode.rewrite.boot3.UpgradeSpringBoot_3_5",
5656
"org.rewrite.java.security.*",
5757
"org.springframework.rewrite.test.*",
5858
"rewrite.test.*"
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
#
2+
# Copyright 2024 the original author or authors.
3+
# <p>
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
# <p>
8+
# https://www.apache.org/licenses/LICENSE-2.0
9+
# <p>
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
#
16+
---
17+
type: specs.openrewrite.org/v1beta/recipe
18+
name: org.springframework.ide.vscode.rewrite.boot3.UpgradeSpringBoot_3_5
19+
displayName: Migrate to Spring Boot 3.5
20+
description: >-
21+
Migrate applications to the latest Spring Boot 3.5 release. This recipe will modify an
22+
application's build files and migrate configuration settings that have
23+
changes between versions.
24+
tags:
25+
- spring
26+
- boot
27+
recipeList:
28+
- org.springframework.ide.vscode.rewrite.boot3.UpgradeSpringBoot_3_4
29+
- org.openrewrite.java.spring.boot3.SpringBootProperties_3_5
30+
- org.openrewrite.java.dependencies.UpgradeDependencyVersion:
31+
groupId: org.springframework.boot
32+
artifactId: "*"
33+
newVersion: 3.5.x
34+
overrideManagedVersion: false
35+
- org.openrewrite.maven.UpgradePluginVersion:
36+
groupId: org.springframework.boot
37+
artifactId: spring-boot-maven-plugin
38+
newVersion: 3.5.x
39+
- org.openrewrite.maven.UpgradeParentVersion:
40+
groupId: org.springframework.boot
41+
artifactId: spring-boot-starter-parent
42+
newVersion: 3.5.x
43+
- org.openrewrite.gradle.plugins.UpgradePluginVersion:
44+
pluginIdPattern: org.springframework.boot
45+
newVersion: 3.5.x
46+
Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
# This file is automatically generated by the GeneratePropertiesMigratorConfiguration class.
2+
# Do not edit this file manually. Update the Spring Boot property metadata upstream instead.
3+
---
4+
type: specs.openrewrite.org/v1beta/recipe
5+
name: org.openrewrite.java.spring.boot3.SpringBootProperties_3_5
6+
displayName: Migrate Spring Boot properties to 3.5
7+
description: Migrate properties found in `application.properties` and `application.yml`.
8+
tags:
9+
- spring
10+
- boot
11+
recipeList:
12+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
13+
oldPropertyKey: management.promethus.metrics.export.pushgateway.base-url
14+
newPropertyKey: management.prometheus.metrics.export.pushgateway.address
15+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
16+
oldPropertyKey: spring.codec.log-request-details
17+
newPropertyKey: spring.http.codec.log-request-details
18+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
19+
oldPropertyKey: spring.codec.max-in-memory-size
20+
newPropertyKey: spring.http.codec.max-in-memory-size
21+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
22+
oldPropertyKey: spring.graphql.path
23+
newPropertyKey: spring.graphql.http.path
24+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
25+
oldPropertyKey: spring.graphql.sse.timeout
26+
newPropertyKey: spring.graphql.http.sse.timeout
27+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
28+
oldPropertyKey: spring.groovy.template.configuration.auto-escape
29+
newPropertyKey: spring.groovy.template.auto-escape
30+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
31+
oldPropertyKey: spring.groovy.template.configuration.auto-indent
32+
newPropertyKey: spring.groovy.template.auto-indent
33+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
34+
oldPropertyKey: spring.groovy.template.configuration.auto-indent-string
35+
newPropertyKey: spring.groovy.template.auto-indent-string
36+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
37+
oldPropertyKey: spring.groovy.template.configuration.auto-new-line
38+
newPropertyKey: spring.groovy.template.auto-new-line
39+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
40+
oldPropertyKey: spring.groovy.template.configuration.base-template-class
41+
newPropertyKey: spring.groovy.template.base-template-class
42+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
43+
oldPropertyKey: spring.groovy.template.configuration.cache-templates
44+
newPropertyKey: spring.groovy.template.cache
45+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
46+
oldPropertyKey: spring.groovy.template.configuration.declaration-encoding
47+
newPropertyKey: spring.groovy.template.declaration-encoding
48+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
49+
oldPropertyKey: spring.groovy.template.configuration.expand-empty-elements
50+
newPropertyKey: spring.groovy.template.expand-empty-elements
51+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
52+
oldPropertyKey: spring.groovy.template.configuration.locale
53+
newPropertyKey: spring.groovy.template.locale
54+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
55+
oldPropertyKey: spring.groovy.template.configuration.new-line-string
56+
newPropertyKey: spring.groovy.template.new-line-string
57+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
58+
oldPropertyKey: spring.groovy.template.configuration.resource-loader-path
59+
newPropertyKey: spring.groovy.template.resource-loader-path
60+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
61+
oldPropertyKey: spring.groovy.template.configuration.use-double-quotes
62+
newPropertyKey: spring.groovy.template.use-double-quotes
63+
- org.openrewrite.java.spring.ChangeSpringPropertyKey:
64+
oldPropertyKey: spring.mvc.converters.preferred-json-mapper
65+
newPropertyKey: spring.http.converters.preferred-json-mapper
66+
67+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
68+
propertyKey: management.signalfx.metrics.export.access-token
69+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
70+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
71+
propertyKey: management.signalfx.metrics.export.batch-size
72+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
73+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
74+
propertyKey: management.signalfx.metrics.export.connect-timeout
75+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
76+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
77+
propertyKey: management.signalfx.metrics.export.enabled
78+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
79+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
80+
propertyKey: management.signalfx.metrics.export.published-histogram-type
81+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
82+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
83+
propertyKey: management.signalfx.metrics.export.read-timeout
84+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
85+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
86+
propertyKey: management.signalfx.metrics.export.source
87+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
88+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
89+
propertyKey: management.signalfx.metrics.export.step
90+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
91+
- org.openrewrite.java.spring.CommentOutSpringPropertyKey:
92+
propertyKey: management.signalfx.metrics.export.uri
93+
comment: "This property is deprecated: Deprecated in Micrometer 1.15.0"
94+

headless-services/spring-boot-language-server/src/main/java/org/springframework/ide/vscode/boot/java/rewrite/SpringBootUpgrade.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ public class SpringBootUpgrade {
5252
versionsToRecipeId.put("3.2", "org.openrewrite.java.spring.boot3.UpgradeSpringBoot_3_2");
5353
versionsToRecipeId.put("3.3", "org.openrewrite.java.spring.boot3.UpgradeSpringBoot_3_3");
5454
versionsToRecipeId.put("3.4", "org.springframework.ide.vscode.rewrite.boot3.UpgradeSpringBoot_3_4");
55+
versionsToRecipeId.put("3.5", "org.springframework.ide.vscode.rewrite.boot3.UpgradeSpringBoot_3_5");
5556
}
5657

5758
public SpringBootUpgrade(SimpleLanguageServer server, RewriteRecipeRepository recipeRepo, JavaProjectFinder projectFinder) {

vscode-extensions/vscode-spring-boot/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -467,8 +467,8 @@
467467
"org.openrewrite.java.testing.junit5.JUnit5BestPractices",
468468
"org.openrewrite.java.testing.junit5.JUnit4to5Migration",
469469
"org.openrewrite.java.spring.boot2.UpgradeSpringBoot_2_7",
470-
"org.openrewrite.java.spring.boot3.UpgradeSpringBoot_3_3",
471470
"org.springframework.ide.vscode.rewrite.boot3.UpgradeSpringBoot_3_4",
471+
"org.springframework.ide.vscode.rewrite.boot3.UpgradeSpringBoot_3_5",
472472
"org.rewrite.java.security.*",
473473
"org.springframework.rewrite.test.*",
474474
"rewrite.test.*"

0 commit comments

Comments
 (0)