Merge gradle support for boot version validation
This commit is contained in:
@@ -52,7 +52,7 @@ public class PrefsInitializer extends AbstractPreferenceInitializer {
|
||||
"org.openrewrite.java.testing.junit5.JUnit5BestPractices",
|
||||
"org.openrewrite.java.testing.junit5.JUnit4to5Migration",
|
||||
"org.openrewrite.java.spring.boot2.UpgradeSpringBoot_2_6",
|
||||
"org.openrewrite.java.spring.boot3.UpgradeSpringBoot_3_0",
|
||||
"org.springframework.sts.java.spring.boot3.UpgradeSpringBoot_3_0",
|
||||
"org.rewrite.java.security.*",
|
||||
"org.springframework.rewrite.test.*",
|
||||
"rewrite.test.*"
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
#
|
||||
# Copyright 2022 the original author or authors.
|
||||
# <p>
|
||||
# Licensed 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
|
||||
# <p>
|
||||
# https://www.apache.org/licenses/LICENSE-2.0
|
||||
# <p>
|
||||
# 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.
|
||||
#
|
||||
---
|
||||
########################################################################################################################
|
||||
# SpringBoot 3_0
|
||||
type: specs.openrewrite.org/v1beta/recipe
|
||||
name: org.springframework.sts.java.spring.boot3.UpgradeSpringBoot_3_0
|
||||
displayName: Upgrade to Spring Boot 3.0 from 2.7
|
||||
description: 'Upgrade to Spring Boot 3.0 from prior 2.x version.'
|
||||
recipeList:
|
||||
- org.openrewrite.maven.AddRepository:
|
||||
id: spring-snapshots
|
||||
url: https://repo.spring.io/snapshot
|
||||
snapshotsEnabled: true
|
||||
- org.openrewrite.maven.AddRepository:
|
||||
id: spring-milestones
|
||||
url: https://repo.spring.io/milestone
|
||||
snapshotsEnabled: false
|
||||
- org.openrewrite.java.spring.boot3.UpgradeSpringBoot_3_0
|
||||
---
|
||||
@@ -31,6 +31,7 @@ public class SpringProcessConnectorService {
|
||||
|
||||
private static final String METRICS = "metrics";
|
||||
public static final String GC_PAUSES = "gcPauses";
|
||||
public static final String MEMORY = "memory";
|
||||
public static final String HEAP_MEMORY = "heapMemory";
|
||||
public static final String NON_HEAP_MEMORY = "nonHeapMemory";
|
||||
|
||||
@@ -176,7 +177,7 @@ public class SpringProcessConnectorService {
|
||||
progressTask.progressDone();
|
||||
|
||||
refreshProcess(new SpringProcessParams(processKey, "", "", ""));
|
||||
refreshProcess(new SpringProcessParams(processKey, METRICS, HEAP_MEMORY, "area:heap"));
|
||||
refreshProcess(new SpringProcessParams(processKey, METRICS, MEMORY, ""));
|
||||
refreshProcess(new SpringProcessParams(processKey, METRICS, GC_PAUSES, ""));
|
||||
}
|
||||
catch (Exception e) {
|
||||
@@ -237,7 +238,7 @@ public class SpringProcessConnectorService {
|
||||
|
||||
try {
|
||||
progressTask.progressEvent(progressMessage);
|
||||
if(METRICS.equals(endpoint) && (HEAP_MEMORY.equals(metricName) || NON_HEAP_MEMORY.equals(metricName))) {
|
||||
if(METRICS.equals(endpoint) && (MEMORY.equals(metricName))) {
|
||||
SpringProcessMemoryMetricsLiveData newMetricsLiveData = connector.refreshMemoryMetrics(this.liveDataProvider.getCurrent(processKey), metricName, springProcessParams.getTags());
|
||||
|
||||
if (newMetricsLiveData != null) {
|
||||
|
||||
@@ -218,7 +218,7 @@
|
||||
"org.openrewrite.java.testing.junit5.JUnit5BestPractices",
|
||||
"org.openrewrite.java.testing.junit5.JUnit4to5Migration",
|
||||
"org.openrewrite.java.spring.boot2.UpgradeSpringBoot_2_6",
|
||||
"org.openrewrite.java.spring.boot3.UpgradeSpringBoot_3_0",
|
||||
"org.springframework.sts.java.spring.boot3.UpgradeSpringBoot_3_0",
|
||||
"org.rewrite.java.security.*",
|
||||
"org.springframework.rewrite.test.*",
|
||||
"rewrite.test.*"
|
||||
|
||||
Reference in New Issue
Block a user