-
Notifications
You must be signed in to change notification settings - Fork 1
/
pom.xml
129 lines (120 loc) · 5.9 KB
/
pom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
<?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
http://maven.apache.org/xsd/maven-4.0.0.xsd">
<!-- Maven version of the xml document.
Currently only 4.0.0 is valid -->
<modelVersion>4.0.0</modelVersion>
<!-- Maven projects are identified by their GAV. The groupId (G) is first,
the artifactId (A) is second, and the version (V) is third. The groupId is
usually a company's domain name reversed. If you do not have a domain then
just use your name as I have -->
<groupId>com.eclipse</groupId>
<!-- This is the name given to the packaged build -->
<artifactId>RestSeBootstrap</artifactId>
<!-- The version of the build. Any value is valid though a number and a
string are common. SNAPSHOT means a project under development. FINAL or no
text is commonly used to refer to a stable production version -->
<version>0.1-SNAPSHOT</version>
<!-- Values can be:
jar - java archive
war - web archive
ear - enterprise archive -->
<packaging>jar</packaging>
<!-- A description of the program -->
<description>A basic SeBootsrap web service project</description>
<!-- properties are values that plugins can use by refering to the tag name. -->
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<!-- New maven guideline prefers release. For backward compatibility the
source and target are here. -->
<maven.compiler.release>17</maven.compiler.release>
<maven.compiler.source>17</maven.compiler.source>
<maven.compiler.target>17</maven.compiler.target>
<jakartaee-api.version>10.0.0</jakartaee-api.version>
<exec.mainClass>com.eclipse.restsebootstrap.RestBootstrap</exec.mainClass>
</properties>
<!-- Here we list the Jersey libraries that must be downloaded and
added to your project to be able to use them in your program -->
<dependencies>
<!-- The following three dependencies are required to use the Jersey library -->
<dependency>
<groupId>org.glassfish.jersey.core</groupId>
<artifactId>jersey-server</artifactId>
<version>3.1.3</version>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.containers</groupId>
<artifactId>jersey-container-jdk-http</artifactId>
<version>3.1.3</version>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.inject</groupId>
<artifactId>jersey-cdi2-se</artifactId>
<version>3.1.3</version>
</dependency>
</dependencies>
<!-- Here we list the plugin libraries that Maven may use to build the
project. These are not added to your program but only used by Maven. -->
<build>
<!-- Maven must be told what you expect it to do and these are called goals.
'clean' deletes the target folder forcing all code to be compiled.
'compile' goes through the source code tree and compiles every source
code file and writes the bytecode to the target folder.
'test' runs all unit tests that are in the project
'package' combines all the files into a jar package.
'exec:java' will execute your program in the same JVM that Maven is running in.
'exec:exec" will execute your program is a new JVM. -->
<defaultGoal>clean verify exec:exec</defaultGoal>
<finalName>${project.artifactId}</finalName>
<plugins>
<plugin>
<!-- This plugin assembles all the dependencies and the compiled
jar into a single executable file. -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>3.6.0</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<archive>
<manifest>
<mainClass>${exec.mainClass}</mainClass>
</manifest>
</archive>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
<finalName>${project.artifactId}</finalName>
<appendAssemblyId>false</appendAssemblyId>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<!-- Enables Maven to run the program as long as any previous
goals, such as compile or test, were all successful. -->
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<mainClass>${exec.mainClass}</mainClass>
<arguments>
<argument>-jar</argument>
<!-- As Maven will produce an assembled and an
unassembled jar file the following argument selects
the assembled jar to be run by Maven -->
<argument>target/${project.artifactId}.jar</argument>
</arguments>
<!-- The type of executable -->
<executable>java</executable>
</configuration>
</plugin>
</plugins>
</build>
</project>