Ralf Ueberfuhr b913e47c13 BAEL-5951: Spring Boot 3 Sample for Native Image builds incl. Runtime Hints (#13047)
* Update Spring Boot, Spring Native and Native Maven Plugin versions

* BAEL-5951: Spring Boot 3 Sample for Native Image builds incl. Runtime Hints

* BAEL-5951: Configure POMs and add Swagger UI runtime hints

* BAEL-5951: Remove Swagger UI runtime hints

* BAEL-5951: Remove Spring Boot3 parent POM from profiles because of JDK17 dependency during build (building the parent POM is even not necessary)

* BAEL-5951: Add tests

* BAEL-5951: Fix tests (PMD naming conventions)
2022-11-24 09:47:54 +01:00

87 lines
3.2 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>spring-boot-3-native</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>spring-boot-3-native</name>
<description>Demo project for Spring Boot</description>
<parent>
<groupId>com.baeldung</groupId>
<artifactId>parent-boot-3</artifactId>
<version>0.0.1-SNAPSHOT</version>
<relativePath>../../parent-boot-3/pom.xml</relativePath>
</parent>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
<version>${spring-doc.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-graphql</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.graalvm.buildtools</groupId>
<artifactId>native-maven-plugin</artifactId>
<configuration>
<!-- Mockito is not supported -->
<skipNativeTests>true</skipNativeTests>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
<profiles>
<!-- The native profile is already defined by the parent POM. -->
<!-- To use this plugin, we need GraalVM (located under $GRAALVM_HOME) and native-builder (located in the $PATH)-->
<profile>
<id>native</id>
<build>
<plugins>
<plugin>
<groupId>org.graalvm.buildtools</groupId>
<artifactId>native-maven-plugin</artifactId>
<executions>
<execution>
<id>build-native</id>
<goals>
<goal>compile-no-fork</goal>
</goals>
<phase>package</phase>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<properties>
<spring-boot.version>3.0.0-RC2</spring-boot.version>
<spring-doc.version>2.0.0-RC1</spring-doc.version>
<native.maven.plugin.version>0.9.17</native.maven.plugin.version>
<start-class>com.baeldung.sample.TodoApplication</start-class>
</properties>
</project>