1- <?xml version =' 1.0' encoding =' UTF-8' ?>
2- <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 http://maven.apache.org/xsd/maven-4.0.0.xsd" >
3- <modelVersion >4.0.0</modelVersion >
4- <groupId >com.example.datastore</groupId >
5- <artifactId >native-image-sample</artifactId >
6- <name >Native Image Sample</name >
7- <url >https://github.com/googleapis/java-datastore</url >
8-
9- <!--
10- The parent pom defines common style checks and testing strategies for our samples.
11- Removing or replacing it should not affect the execution of the samples in anyway.
12- -->
13- <parent >
14- <groupId >com.google.cloud.samples</groupId >
15- <artifactId >shared-configuration</artifactId >
16- <version >1.2.0</version >
17- </parent >
18-
19- <properties >
20- <!-- Java 8 because the Kokoro Sample test uses that Java version -->
21- <maven .compiler.target>1.8</maven .compiler.target>
22- <maven .compiler.source>1.8</maven .compiler.source>
23- <project .build.sourceEncoding>UTF-8</project .build.sourceEncoding>
24- </properties >
25-
26- <dependencyManagement >
27- <dependencies >
28- <dependency >
29- <groupId >com.google.cloud</groupId >
30- <artifactId >libraries-bom</artifactId >
31- <version >26.43.0</version >
32- <type >pom</type >
33- <scope >import</scope >
34- </dependency >
35- </dependencies >
36- </dependencyManagement >
37-
38- <dependencies >
39- <dependency >
40- <groupId >com.google.cloud</groupId >
41- <artifactId >google-cloud-datastore</artifactId >
42- </dependency >
43-
44- <dependency >
45- <groupId >junit</groupId >
46- <artifactId >junit</artifactId >
47- <version >4.13.2</version >
48- <scope >test</scope >
49- </dependency >
50- <dependency >
51- <groupId >com.google.truth</groupId >
52- <artifactId >truth</artifactId >
53- <version >1.4.3</version >
54- <scope >test</scope >
55- </dependency >
56- </dependencies >
57-
58- <build >
59- <plugins >
60- <plugin >
61- <groupId >org.apache.maven.plugins</groupId >
62- <artifactId >maven-jar-plugin</artifactId >
63- <configuration >
64- <archive >
65- <manifest >
66- <mainClass >com.example.datastore.NativeImageDatastoreSample</mainClass >
67- </manifest >
68- </archive >
69- </configuration >
70- </plugin >
71- </plugins >
72- </build >
73-
74- <!-- Native Profile-->
75- <profiles >
76- <profile >
77- <id >native</id >
78-
79- <dependencies >
80- <dependency >
81- <groupId >org.junit.vintage</groupId >
82- <artifactId >junit-vintage-engine</artifactId >
83- <version >5.10.2</version >
84- <scope >test</scope >
85- </dependency >
86- <dependency >
87- <groupId >org.graalvm.buildtools</groupId >
88- <artifactId >junit-platform-native</artifactId >
89- <version >0.10.2</version >
90- <scope >test</scope >
91- </dependency >
92- </dependencies >
93-
94- <build >
95- <plugins >
96- <plugin >
97- <groupId >org.apache.maven.plugins</groupId >
98- <artifactId >maven-surefire-plugin
99- </artifactId > <!-- Must use older version of surefire plugin for native-image testing. -->
100- <version >3.2.5</version >
101- <configuration >
102- <includes >
103- <include >**/IT*</include >
104- </includes >
105- </configuration >
106- </plugin >
107- <plugin >
108- <groupId >org.graalvm.buildtools</groupId >
109- <artifactId >native-maven-plugin</artifactId >
110- <version >0.10.2</version >
111- <extensions >true</extensions >
112- <configuration >
113- <mainClass >com.example.datastore.NativeImageDatastoreSample</mainClass >
114- <buildArgs >
115- <buildArg >--no-fallback</buildArg >
116- <buildArg >--no-server</buildArg >
117- </buildArgs >
118- </configuration >
119- <executions >
120- <execution >
121- <id >build-native</id >
122- <goals >
123- <goal >build</goal >
124- <goal >test</goal >
125- </goals >
126- <phase >package</phase >
127- </execution >
128- <execution >
129- <id >test-native</id >
130- <goals >
131- <goal >test</goal >
132- </goals >
133- <phase >test</phase >
134- </execution >
135- </executions >
136- </plugin >
137- </plugins >
138- </build >
139- </profile >
140- </profiles >
141- </project >
0 commit comments