This commit is contained in:
hengyunabc 2023-05-15 19:38:17 +08:00
parent 005fa1707b
commit 8593b1d77c
7 changed files with 33 additions and 15 deletions

View File

@ -17,7 +17,7 @@ jobs:
distribution: 'zulu' distribution: 'zulu'
cache: 'maven' cache: 'maven'
- name: Build with Maven - name: Build with Maven
run: mvn clean package -P full run: mvn clean install -P full
windows_build: windows_build:
runs-on: windows-2019 runs-on: windows-2019
@ -33,7 +33,7 @@ jobs:
distribution: 'zulu' distribution: 'zulu'
cache: 'maven' cache: 'maven'
- name: Build with Maven - name: Build with Maven
run: mvn clean package -P full run: mvn clean install -P full
macos_build: macos_build:
runs-on: macos-latest runs-on: macos-latest
@ -49,4 +49,4 @@ jobs:
distribution: 'zulu' distribution: 'zulu'
cache: 'maven' cache: 'maven'
- name: Build with Maven - name: Build with Maven
run: mvn clean package -P full run: mvn clean install -P full

View File

@ -15,6 +15,10 @@
<name>${project.artifactId}</name> <name>${project.artifactId}</name>
<url>https://github.com/alibaba/arthas</url> <url>https://github.com/alibaba/arthas</url>
<properties>
<it.pom.includes>*/pom.xml</it.pom.includes>
</properties>
<dependencyManagement> <dependencyManagement>
<dependencies> <dependencies>
<dependency> <dependency>
@ -64,6 +68,19 @@
</dependency> </dependency>
</dependencies> </dependencies>
<profiles>
<profile>
<id>jdk-lt-17</id>
<activation>
<jdk>[1.8,17)</jdk>
</activation>
<properties>
<!-- spring boot3 测试只支持 jdk 17 及之后版本 -->
<it.pom.includes>arthas-spring-boot-starter-example/pom.xml</it.pom.includes>
</properties>
</profile>
</profiles>
<build> <build>
<plugins> <plugins>
<plugin> <plugin>
@ -79,12 +96,13 @@
<streamLogs>true</streamLogs> <streamLogs>true</streamLogs>
<preBuildHookScript>setup</preBuildHookScript> <preBuildHookScript>setup</preBuildHookScript>
<postBuildHookScript>verify</postBuildHookScript> <postBuildHookScript>verify</postBuildHookScript>
<pomIncludes><pomInclude>${it.pom.includes}</pomInclude></pomIncludes>
</configuration> </configuration>
<executions> <executions>
<execution> <execution>
<id>integration-test</id> <id>integration-test</id>
<phase>test</phase>
<goals> <goals>
<goal>install</goal>
<goal>run</goal> <goal>run</goal>
</goals> </goals>
</execution> </execution>

View File

@ -5,17 +5,17 @@
<parent> <parent>
<groupId>org.springframework.boot</groupId> <groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId> <artifactId>spring-boot-starter-parent</artifactId>
<version>@spring-boot.version@</version> <version>@spring-boot3.version@</version>
<relativePath /> <!-- lookup parent from repository --> <relativePath /> <!-- lookup parent from repository -->
</parent> </parent>
<groupId>com.example</groupId> <groupId>com.example</groupId>
<artifactId>arthas-spring-boot-starter-example</artifactId> <artifactId>arthas-spring-boot3-starter-example</artifactId>
<version>0.0.1-SNAPSHOT</version> <version>0.0.1-SNAPSHOT</version>
<name>arthas-spring-boot-starter-example</name> <name>arthas-spring-boot3-starter-example</name>
<description>Demo project for Spring Boot</description> <description>Demo project for Spring Boot</description>
<properties> <properties>
<java.version>1.8</java.version> <java.version>17</java.version>
</properties> </properties>
<dependencies> <dependencies>

View File

@ -1,4 +1,4 @@
package com.example.arthasspringbootstarterexample; package com.example.arthasspringboot3starterexample;
import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeUnit;
@ -6,10 +6,10 @@ import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication @SpringBootApplication
public class ArthasSpringBootStarterExampleApplication { public class ArthasSpringBoot3StarterExampleApplication {
public static void main(String[] args) throws InterruptedException { public static void main(String[] args) throws InterruptedException {
SpringApplication.run(ArthasSpringBootStarterExampleApplication.class, args); SpringApplication.run(ArthasSpringBoot3StarterExampleApplication.class, args);
System.out.println("xxxxxxxxxxxxxxxxxx"); System.out.println("xxxxxxxxxxxxxxxxxx");
TimeUnit.SECONDS.sleep(3); TimeUnit.SECONDS.sleep(3);
System.exit(0); System.exit(0);

View File

@ -1,10 +1,10 @@
package com.example.arthasspringbootstarterexample; package com.example.arthasspringbootstarterexample3;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.test.context.SpringBootTest;
@SpringBootTest @SpringBootTest
class ArthasSpringBootStarterExampleApplicationTests { class ArthasSpringBoot3StarterExampleApplicationTests {
@Test @Test
void contextLoads() { void contextLoads() {

View File

@ -1,2 +0,0 @@
com.alibaba.arthas.spring.ArthasConfiguration
com.alibaba.arthas.spring.endpoints.ArthasEndPointAutoConfiguration

View File

@ -0,0 +1,2 @@
com.alibaba.arthas.spring.ArthasConfiguration
com.alibaba.arthas.spring.endpoints.ArthasEndPointAutoConfiguration