Merge "[DMAAP-DR-PROV] Remove aaf & cadi"
[dmaap/datarouter.git] / datarouter-node / pom.xml
1 <!--
2   ============LICENSE_START==================================================
3   * org.onap.dmaap
4   * ===========================================================================
5   * Copyright © 2017 AT&T Intellectual Property. All rights reserved.
6   * Modifications Copyright (C) 2018 Nokia. All rights reserved.
7   * Modifications Copyright (C) 2021 Samsung Electronics. All rights reserved.
8   * ===========================================================================
9   * Licensed under the Apache License, Version 2.0 (the "License");
10   * you may not use this file except in compliance with the License.
11   * You may obtain a copy of the License at
12   *
13    *      http://www.apache.org/licenses/LICENSE-2.0
14   *
15    * Unless required by applicable law or agreed to in writing, software
16   * distributed under the License is distributed on an "AS IS" BASIS,
17   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18   * See the License for the specific language governing permissions and
19   * limitations under the License.
20   * ============LICENSE_END====================================================
21   *
22   * ECOMP is a trademark and service mark of AT&T Intellectual Property.
23   *
24 -->
25 <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/maven-v4_0_0.xsd">
26     <modelVersion>4.0.0</modelVersion>
27     <parent>
28         <groupId>org.onap.dmaap.datarouter</groupId>
29         <artifactId>parent</artifactId>
30         <version>${revision}</version>
31         <relativePath>../pom.xml</relativePath>
32     </parent>
33     <artifactId>datarouter-node</artifactId>
34     <packaging>jar</packaging>
35     <url>https://docs.onap.org/en/latest/submodules/dmaap/datarouter.git/docs/index.html</url>
36     <properties>
37         <sitePath>/content/sites/site/${project.groupId}/${project.artifactId}/${project.version}</sitePath>
38         <docker.location>${basedir}/target/${project.artifactId}</docker.location>
39         <datarouter.node.image.name>${docker.image.root}${project.artifactId}</datarouter.node.image.name>
40         <sonar.exclusions>src/main/java/org/onap/dmaap/datarouter/node/NodeMain.java</sonar.exclusions>
41         <sonar.language>java</sonar.language>
42         <sonar.skip>false</sonar.skip>
43     </properties>
44     <dependencies>
45         <dependency>
46             <groupId>org.apache.commons</groupId>
47             <artifactId>commons-lang3</artifactId>
48         </dependency>
49         <dependency>
50             <groupId>org.slf4j</groupId>
51             <artifactId>slf4j-api</artifactId>
52         </dependency>
53         <dependency>
54             <groupId>commons-codec</groupId>
55             <artifactId>commons-codec</artifactId>
56         </dependency>
57         <dependency>
58             <groupId>commons-io</groupId>
59             <artifactId>commons-io</artifactId>
60         </dependency>
61         <dependency>
62             <groupId>org.json</groupId>
63             <artifactId>json</artifactId>
64         </dependency>
65         <dependency>
66             <groupId>com.att.eelf</groupId>
67             <artifactId>eelf-core</artifactId>
68             <exclusions>
69                 <exclusion>
70                     <artifactId>powermock-api-mockito</artifactId>
71                     <groupId>org.powermock</groupId>
72                 </exclusion>
73             </exclusions>
74         </dependency>
75         <dependency>
76             <groupId>ch.qos.logback</groupId>
77             <artifactId>logback-classic</artifactId>
78         </dependency>
79         <dependency>
80             <groupId>ch.qos.logback</groupId>
81             <artifactId>logback-core</artifactId>
82         </dependency>
83         <dependency>
84             <groupId>javax.servlet</groupId>
85             <artifactId>javax.servlet-api</artifactId>
86         </dependency>
87         <dependency>
88             <groupId>org.eclipse.jetty</groupId>
89             <artifactId>jetty-server</artifactId>
90         </dependency>
91         <dependency>
92             <groupId>org.eclipse.jetty</groupId>
93             <artifactId>jetty-util</artifactId>
94         </dependency>
95         <dependency>
96             <groupId>org.eclipse.jetty</groupId>
97             <artifactId>jetty-servlet</artifactId>
98         </dependency>
99         <dependency>
100             <groupId>org.eclipse.jetty</groupId>
101             <artifactId>jetty-http</artifactId>
102         </dependency>
103         <dependency>
104             <groupId>com.intellij</groupId>
105             <artifactId>annotations</artifactId>
106         </dependency>
107         <dependency>
108             <groupId>org.hamcrest</groupId>
109             <artifactId>hamcrest-all</artifactId>
110             <scope>test</scope>
111         </dependency>
112         <dependency>
113             <groupId>junit</groupId>
114             <artifactId>junit</artifactId>
115             <scope>test</scope>
116         </dependency>
117         <dependency>
118             <groupId>org.sonatype.http-testing-harness</groupId>
119             <artifactId>junit-runner</artifactId>
120             <scope>test</scope>
121             <exclusions>
122                 <exclusion>
123                     <artifactId>powermock-api-mockito</artifactId>
124                     <groupId>org.powermock</groupId>
125                 </exclusion>
126                 <exclusion>
127                     <artifactId>powermock-reflect</artifactId>
128                     <groupId>org.powermock</groupId>
129                 </exclusion>
130                 <exclusion>
131                     <artifactId>jetty-security</artifactId>
132                     <groupId>org.eclipse.jetty</groupId>
133                 </exclusion>
134                 <exclusion>
135                     <artifactId>jsr305</artifactId>
136                     <groupId>com.google.code.findbugs</groupId>
137                 </exclusion>
138             </exclusions>
139         </dependency>
140         <dependency>
141             <groupId>org.mockito</groupId>
142             <artifactId>mockito-core</artifactId>
143             <scope>test</scope>
144         </dependency>
145         <dependency>
146             <groupId>org.powermock</groupId>
147             <artifactId>powermock-module-junit4</artifactId>
148             <scope>test</scope>
149         </dependency>
150         <dependency>
151             <groupId>org.powermock</groupId>
152             <artifactId>powermock-api-mockito2</artifactId>
153             <scope>test</scope>
154         </dependency>
155         <dependency>
156             <groupId>org.powermock</groupId>
157             <artifactId>powermock-api-support</artifactId>
158             <scope>test</scope>
159         </dependency>
160         <dependency>
161             <groupId>org.powermock</groupId>
162             <artifactId>powermock-core</artifactId>
163             <scope>test</scope>
164         </dependency>
165         <dependency>
166             <groupId>org.powermock</groupId>
167             <artifactId>powermock-module-junit4-rule</artifactId>
168         </dependency>
169         <dependency>
170             <groupId>net.bytebuddy</groupId>
171             <artifactId>byte-buddy</artifactId>
172         </dependency>
173         <dependency>
174             <groupId>net.bytebuddy</groupId>
175             <artifactId>byte-buddy-agent</artifactId>
176         </dependency>
177         <dependency>
178             <groupId>org.objenesis</groupId>
179             <artifactId>objenesis</artifactId>
180         </dependency>
181         <dependency>
182             <groupId>org.javassist</groupId>
183             <artifactId>javassist</artifactId>
184         </dependency>
185         <dependency>
186             <groupId>org.awaitility</groupId>
187             <artifactId>awaitility</artifactId>
188             <version>3.1.6</version>
189             <scope>test</scope>
190         </dependency>
191     </dependencies>
192     <profiles>
193         <profile>
194             <id>docker</id>
195             <properties>
196                 <skipTests>true</skipTests>
197             </properties>
198             <build>
199                 <plugins>
200                     <plugin>
201                         <groupId>org.codehaus.gmaven</groupId>
202                         <artifactId>gmaven-plugin</artifactId>
203                     </plugin>
204                     <plugin>
205                         <groupId>io.fabric8</groupId>
206                         <artifactId>docker-maven-plugin</artifactId>
207                         <configuration>
208                             <images>
209                                 <image>
210                                     <name>${datarouter.node.image.name}</name>
211                                     <build>
212                                         <cleanup>try</cleanup>
213                                         <noCache>true</noCache>
214                                         <optimise>true</optimise>
215                                         <contextDir>${basedir}/target/docker-stage</contextDir>
216                                         <dockerFile>Dockerfile</dockerFile>
217                                         <tags>
218                                             <tag>${dockertag1}</tag>
219                                             <tag>${dockertag2}</tag>
220                                         </tags>
221                                     </build>
222                                 </image>
223                             </images>
224                         </configuration>
225                         <executions>
226                             <execution>
227                                 <id>generate-images</id>
228                                 <phase>install</phase>
229                                 <goals>
230                                     <goal>build</goal>
231                                 </goals>
232                             </execution>
233                             <execution>
234                                 <id>push-images</id>
235                                 <phase>deploy</phase>
236                                 <goals>
237                                     <goal>push</goal>
238                                 </goals>
239                             </execution>
240                         </executions>
241                     </plugin>
242                 </plugins>
243             </build>
244         </profile>
245     </profiles>
246     <build>
247         <finalName>datarouter-node</finalName>
248         <resources>
249             <resource>
250                 <directory>src/main/resources</directory>
251                 <filtering>true</filtering>
252                 <includes>
253                     <include>**/*.properties</include>
254                 </includes>
255             </resource>
256             <resource>
257                 <directory>src/main/resources</directory>
258                 <filtering>true</filtering>
259                 <includes>
260                     <include>**/logback.xml</include>
261                 </includes>
262             </resource>
263         </resources>
264         <plugins>
265             <plugin>
266                 <groupId>org.apache.maven.plugins</groupId>
267                 <artifactId>maven-compiler-plugin</artifactId>
268             </plugin>
269             <plugin>
270                 <artifactId>maven-assembly-plugin</artifactId>
271                 <version>2.4</version>
272                 <configuration>
273                     <descriptorRefs>
274                         <descriptorRef>jar-with-dependencies</descriptorRef>
275                     </descriptorRefs>
276                     <outputDirectory>${basedir}/target/docker-stage/opt/app/datartr/lib</outputDirectory>
277                     <archive>
278                         <manifest>
279                             <addClasspath>true</addClasspath>
280                             <mainClass>org.onap.dmaap.datarouter.node.NodeRunner</mainClass>
281                         </manifest>
282                     </archive>
283                 </configuration>
284                 <executions>
285                     <execution>
286                         <id>make-assembly</id>
287                         <!-- this is used for inheritance merges -->
288                         <phase>package</phase>
289                         <!-- bind to the packaging phase -->
290                         <goals>
291                             <goal>single</goal>
292                         </goals>
293                     </execution>
294                 </executions>
295             </plugin>
296             <plugin>
297                 <groupId>org.apache.maven.plugins</groupId>
298                 <artifactId>maven-resources-plugin</artifactId>
299                 <version>2.7</version>
300                 <executions>
301                     <execution>
302                         <id>copy-docker-file</id>
303                         <phase>validate</phase>
304                         <goals>
305                             <goal>copy-resources</goal>
306                         </goals>
307                         <configuration>
308                             <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
309                             <overwrite>true</overwrite>
310                             <resources>
311                                 <resource>
312                                     <directory>${basedir}/src/main/resources/docker</directory>
313                                     <filtering>true</filtering>
314                                     <includes>
315                                         <include>Dockerfile</include>
316                                     </includes>
317                                 </resource>
318                             </resources>
319                         </configuration>
320                     </execution>
321                     <execution>
322                         <id>copy-startup-script</id>
323                         <phase>validate</phase>
324                         <goals>
325                             <goal>copy-resources</goal>
326                         </goals>
327                         <configuration>
328                             <outputDirectory>${basedir}/target/docker-stage/opt</outputDirectory>
329                             <overwrite>true</overwrite>
330                             <resources>
331                                 <resource>
332                                     <directory>${basedir}/src/main/resources/docker</directory>
333                                     <filtering>true</filtering>
334                                     <includes>
335                                         <include>startup.sh</include>
336                                     </includes>
337                                 </resource>
338                             </resources>
339                         </configuration>
340                     </execution>
341                 </executions>
342             </plugin>
343             <plugin>
344                 <groupId>org.apache.maven.plugins</groupId>
345                 <artifactId>maven-javadoc-plugin</artifactId>
346             </plugin>
347             <plugin>
348                 <groupId>org.apache.maven.plugins</groupId>
349                 <artifactId>maven-source-plugin</artifactId>
350             </plugin>
351             <plugin>
352                 <groupId>org.codehaus.mojo</groupId>
353                 <artifactId>cobertura-maven-plugin</artifactId>
354             </plugin>
355             <plugin>
356                 <groupId>org.jacoco</groupId>
357                 <artifactId>jacoco-maven-plugin</artifactId>
358                 <configuration>
359                     <excludes>
360                         <exclude>src/main/java/org/onap/dmaap/datarouter/node/NodeRunner.java</exclude>
361                     </excludes>
362                 </configuration>
363             </plugin>
364             <plugin>
365                 <groupId>org.codehaus.mojo</groupId>
366                 <artifactId>properties-maven-plugin</artifactId>
367             </plugin>
368         </plugins>
369     </build>
370 </project>