Dan K
2019-07-22 16a11f2775b6ab759e3cce2fb4f4b12c5c88f76a
commit | author | age
81fbcf 1 <?xml version="1.0" encoding="UTF-8"?>
c1c73e 2
DK 3 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4   xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
81fbcf 5   <modelVersion>4.0.0</modelVersion>
c1c73e 6
81fbcf 7   <groupId>com.redhat.training.example</groupId>
DK 8   <artifactId>todo-api</artifactId>
9   <version>1.0.0-SNAPSHOT</version>
10   <packaging>war</packaging>
c1c73e 11   <name>ToDo API Thorntail Example</name>
DK 12   <description>ToDo API microservice using Thorntail</description>
81fbcf 13
DK 14   <properties>
c1c73e 15     <!-- Explicitly declaring the source encoding eliminates the following
DK 16       message: -->
17     <!-- [WARNING] Using platform encoding (UTF-8 actually) to copy filtered
18       resources, i.e. build is platform dependent! -->
81fbcf 19     <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
c1c73e 20     <failOnMissingWebXml>false</failOnMissingWebXml>
DK 21
22     <!-- Thorntail dependency versions -->
23     <version.thorntail>2.4.0.Final</version.thorntail>
24
25     <!-- other plugin versions -->
26     <version.compiler.plugin>3.1</version.compiler.plugin>
27     <version.surefire.plugin>2.16</version.surefire.plugin>
28     <version.war.plugin>2.5</version.war.plugin>
29     <version.fabric8.plugin>4.1.0</version.fabric8.plugin>
30
31     <!-- maven-compiler-plugin -->
32     <maven.compiler.target>1.8</maven.compiler.target>
33     <maven.compiler.source>1.8</maven.compiler.source>
81fbcf 34   </properties>
c1c73e 35
81fbcf 36
DK 37   <dependencyManagement>
38     <dependencies>
39       <dependency>
c1c73e 40         <groupId>io.thorntail</groupId>
81fbcf 41         <artifactId>bom-all</artifactId>
c1c73e 42         <version>${version.thorntail}</version>
81fbcf 43         <scope>import</scope>
DK 44         <type>pom</type>
45       </dependency>
46     </dependencies>
47   </dependencyManagement>
48
c1c73e 49   <dependencies>
DK 50     <dependency>
16a11f 51       <groupId>javax</groupId>
DK 52       <artifactId>javaee-api</artifactId>
53       <version>7.0</version>
54       <scope>provided</scope>
55     </dependency>
56     <dependency>
57       <groupId>io.thorntail</groupId>
58       <artifactId>jaxrs-jsonp</artifactId>
59     </dependency>
60     <dependency>
61       <groupId>io.thorntail</groupId>
62       <artifactId>jpa</artifactId>
63     </dependency>
64     <dependency>
65       <groupId>io.thorntail</groupId>
66       <artifactId>ejb</artifactId>
67     </dependency>
68     <dependency>
69       <groupId>io.thorntail</groupId>
70       <artifactId>datasources</artifactId>
71     </dependency>
72     <dependency>
c1c73e 73       <groupId>io.thorntail</groupId>
DK 74       <artifactId>cdi</artifactId>
75     </dependency>
76     <dependency>
77       <groupId>io.thorntail</groupId>
78       <artifactId>jaxrs</artifactId>
16a11f 79     </dependency>
DK 80     <dependency>
81       <groupId>mysql</groupId>
82       <artifactId>mysql-connector-java</artifactId>
83       <version>${version.mysql}</version>
c1c73e 84     </dependency>
DK 85   </dependencies>
86
81fbcf 87   <build>
c1c73e 88     <!-- Maven will append the version to the finalName (which is the name
DK 89          given to the generated war, and hence the context root) -->
90     <finalName>hello</finalName>
81fbcf 91     <plugins>
c1c73e 92       <!-- The Thorntail Maven plugin creates an uber jar -->
DK 93       <!-- To use, run: mvn thorntail:run -->
81fbcf 94       <plugin>
c1c73e 95         <groupId>io.thorntail</groupId>
DK 96         <artifactId>thorntail-maven-plugin</artifactId>
97         <version>${version.thorntail}</version>
81fbcf 98         <executions>
DK 99           <execution>
100             <goals>
101               <goal>package</goal>
102             </goals>
103           </execution>
104         </executions>
105       </plugin>
106       <plugin>
107         <groupId>io.fabric8</groupId>
108         <artifactId>fabric8-maven-plugin</artifactId>
c1c73e 109         <version>${version.fabric8.plugin}</version>
81fbcf 110         <executions>
DK 111           <execution>
c1c73e 112             <id>fmp</id>
81fbcf 113             <goals>
DK 114               <goal>resource</goal>
115               <goal>build</goal>
116             </goals>
117           </execution>
118         </executions>
119       </plugin>
120     </plugins>
121   </build>
c1c73e 122
81fbcf 123 </project>