summaryrefslogtreecommitdiffstats
path: root/pom.xml
blob: f085ec23639116472c0102009facb79317718fa9 (plain)
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
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
<?xml version="1.0" encoding="UTF-8"?>
<!--
  ============LICENSE_START=======================================================
   Copyright (C) 2019 Nordix Foundation.
  ================================================================================
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

  SPDX-License-Identifier: Apache-2.0
  ============LICENSE_END=========================================================
-->

<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">
    <modelVersion>4.0.0</modelVersion>

    <groupId>org.onap.dcaegen2.services</groupId>
    <artifactId>pm-mapper</artifactId>
    <version>1.3.0-SNAPSHOT</version>

    <parent>
        <groupId>org.onap.oparent</groupId>
        <artifactId>oparent</artifactId>
        <version>2.0.0</version>
    </parent>

    <name>dcaegen2-services-pm-mapper</name>
    <description>Maps PM measurement data from XML to VES</description>
    <packaging>jar</packaging>

    <properties>
        <!-- Dependency Versions -->
        <lombok.version>1.18.4</lombok.version>
        <sl4j.version>1.7.25</sl4j.version>
        <logback.version>1.2.3</logback.version>
        <reactor.version>3.2.3.RELEASE</reactor.version>
        <undertow.version>2.0.27.Final</undertow.version>
        <gson.version>2.8.5</gson.version>
        <freemarker.version>2.3.28</freemarker.version>
        <commons.io.version>2.6</commons.io.version>
        <!-- Testing.Test Dependencies -->
        <junit.version>5.3.2</junit.version>
        <mockito.version>2.23.4</mockito.version>
        <mockito-ju5-ext.version>2.23.4</mockito-ju5-ext.version>
        <powermock.version>2.0.0</powermock.version>
        <mockserver.version>3.10.8</mockserver.version>
        <junit4.version>4.12</junit4.version>
        <jsonschema.version>1.3.0</jsonschema.version>
        <xerces.version>2.11.0</xerces.version>
        <reactor.test>3.1.0.RELEASE</reactor.test>
        <!-- Plugin Versions -->
        <jacoco.version>0.8.2</jacoco.version>
        <surefire.version>2.22.0</surefire.version>
        <git-commit.version>3.0.0</git-commit.version>
        <build-helper.version>3.0.0</build-helper.version>
        <docker-maven.version>0.30.0</docker-maven.version>
        <maven-jar.version>3.1.2</maven-jar.version>
        <dependencies.version>3.1.1</dependencies.version>
        <!-- Plugin Settings -->
        <image-name>${docker.push.registry}/onap/${project.groupId}.${project.artifactId}</image-name>
        <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
        <timestamp>${maven.build.timestamp}</timestamp>
        <sonar.language>java</sonar.language>
        <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
        <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
        <sonar.jacoco.reportPaths>${project.build.directory}/coverage-reports/jacoco.exec</sonar.jacoco.reportPaths>
        <sonar.jacoco.itReportPath>${project.build.directory}/coverage-reports/jacoco-it.exec</sonar.jacoco.itReportPath>
        <sonar.projectVersion>${project.version}</sonar.projectVersion>
        <compiler.target.version>1.8</compiler.target.version>
        <compiler.source.version>1.8</compiler.source.version>
        <onap.logging.version>1.2.2</onap.logging.version>
        <classpath.separator>@@</classpath.separator>
        <pmmapper.main.class>org.onap.dcaegen2.services.pmmapper.App</pmmapper.main.class>
        <dep.dir.name>libs</dep.dir.name>
        <ext.dep.dir.path>${dep.dir.name}/external</ext.dep.dir.path>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <version>${lombok.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>io.projectreactor</groupId>
            <artifactId>reactor-core</artifactId>
            <version>${reactor.version}</version>
        </dependency>
        <dependency>
            <groupId>io.undertow</groupId>
            <artifactId>undertow-core</artifactId>
            <version>${undertow.version}</version>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>${sl4j.version}</version>
        </dependency>
        <dependency>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
            <version>${logback.version}</version>
        </dependency>
        <dependency>
            <groupId>org.onap.logging-analytics</groupId>
            <artifactId>logging-slf4j</artifactId>
            <version>${onap.logging.version}</version>
        </dependency>
        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>servlet-api</artifactId>
            <version>2.5</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
            <version>${gson.version}</version>
        </dependency>
        <dependency>
            <groupId>org.freemarker</groupId>
            <artifactId>freemarker</artifactId>
            <version>${freemarker.version}</version>
        </dependency>
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>${commons.io.version}</version>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-engine</artifactId>
            <version>${junit.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-junit-jupiter</artifactId>
            <version>${mockito-ju5-ext.version}</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-core</artifactId>
            <version>${mockito.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.powermock</groupId>
            <artifactId>powermock-module-junit4</artifactId>
            <version>${powermock.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.vintage</groupId>
            <artifactId>junit-vintage-engine</artifactId>
            <version>${junit.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.powermock</groupId>
            <artifactId>powermock-api-mockito2</artifactId>
            <version>${powermock.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mock-server</groupId>
            <artifactId>mockserver-netty</artifactId>
            <version>${mockserver.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mock-server</groupId>
            <artifactId>mockserver-client-java</artifactId>
            <version>${mockserver.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-params</artifactId>
            <version>${junit.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>io.projectreactor</groupId>
            <artifactId>reactor-test</artifactId>
            <version>${reactor.test}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.everit.json</groupId>
            <artifactId>org.everit.json.schema</artifactId>
            <version>${jsonschema.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>xerces</groupId>
            <artifactId>xercesImpl</artifactId>
            <version>${xerces.version}</version>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>pl.project13.maven</groupId>
                <artifactId>git-commit-id-plugin</artifactId>
                <version>${git-commit.version}</version>
                <configuration>
                    <dateFormat>${maven.build.timestamp.format}</dateFormat>
                </configuration>
                <executions>
                    <execution>
                        <id>get-git-info</id>
                        <goals>
                            <goal>revision</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <version>${dependencies.version}</version>
                <configuration>
                    <silent>true</silent>
                    <includeScope>runtime</includeScope>
                    <pathSeparator>${classpath.separator}</pathSeparator>
                </configuration>
                <executions>
                    <execution>
                        <id>copy-external-dependencies</id>
                        <phase>prepare-package</phase>
                        <goals>
                            <goal>copy-dependencies</goal>
                            <goal>build-classpath</goal>
                        </goals>
                        <configuration>
                            <excludeGroupIds>${project.parent.groupId}</excludeGroupIds>
                            <outputDirectory>${project.build.directory}/${ext.dep.dir.path}</outputDirectory>
                            <prefix>./${ext.dep.dir.path}</prefix>
                            <outputProperty>classpath.external</outputProperty>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <version>${build-helper.version}</version>
                <executions>
                    <execution>
                        <id>fix-classpath-separator</id>
                        <phase>prepare-package</phase>
                        <goals>
                            <goal>regex-properties</goal>
                        </goals>
                        <configuration>
                            <regexPropertySettings>
                                <regexPropertySetting>
                                    <name>classpath.external</name>
                                    <value>${classpath.external}</value>
                                    <regex>${classpath.separator}</regex>
                                    <replacement xml:space="preserve"> </replacement>
                                </regexPropertySetting>
                            </regexPropertySettings>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>io.fabric8</groupId>
                <artifactId>docker-maven-plugin</artifactId>
                <version>${docker-maven.version}</version>
                <configuration>
                    <images>
                        <image>
                            <name>onap/${project.groupId}.${project.artifactId}</name>
                            <registry>${onap.nexus.dockerregistry.daily}</registry>
                            <build>
                                <contextDir>${project.basedir}</contextDir>
                                <dockerFile>${project.build.outputDirectory}/Dockerfile</dockerFile>
                                <args>
                                    <JAR>${project.build.finalName}.jar</JAR>
                                </args>
                                <cleanup>none</cleanup>
                                <tags>
                                    <tag>${project.version}</tag>
                                    <tag>${project.version}-${maven.build.timestamp}Z</tag>
                                </tags>
                            </build>
                        </image>
                    </images>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>${maven-jar.version}</version>
                <configuration>
                    <archive>
                        <manifest>
                            <mainClass>${pmmapper.main.class}</mainClass>
                            <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                            <addBuildEnvironmentEntries>true</addBuildEnvironmentEntries>
                            <useUniqueVersions>false</useUniqueVersions> <!-- workaround for MJAR-156 -->
                        </manifest>
                        <manifestEntries>
                            <Class-Path>${classpath.external}</Class-Path>
                            <Git-Branch>${git.branch}</Git-Branch>
                            <Git-Build-Host>${git.build.host}</Git-Build-Host>
                            <Git-Build-Time>${git.build.time}</Git-Build-Time>
                            <Git-Build-User-Email>${git.build.user.email}</Git-Build-User-Email>
                            <Git-Build-User-Name>${git.build.user.name}</Git-Build-User-Name>
                            <Git-Build-Version>${git.build.version}</Git-Build-Version>
                            <Git-Closest-Tag-Name>${git.closest.tag.name}</Git-Closest-Tag-Name>
                            <Git-Commit-Id>${git.commit.id}</Git-Commit-Id>
                            <Git-Commit-Message-Short>${git.commit.message.short}</Git-Commit-Message-Short>
                            <Git-Commit-Time>${git.commit.time}</Git-Commit-Time>
                            <Git-Commit-User-Email>${git.commit.user.email}</Git-Commit-User-Email>
                            <Git-Commit-User-Name>${git.commit.user.name}</Git-Commit-User-Name>
                        </manifestEntries>
                    </archive>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>${surefire.version}</version>
                <configuration combine.self="override">
                    <useSystemClassLoader>false</useSystemClassLoader>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-failsafe-plugin</artifactId>
                <version>${surefire.version}</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <source>${maven.compiler.source}</source>
                    <target>${maven.compiler.target}</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
                <version>${jacoco.version}</version>
                <executions>
                    <execution>
                        <id>jacoco-instrument</id>
                        <goals>
                            <goal>instrument</goal>
                        </goals>
                    </execution>
                    <execution>
                        <id>jacoco-restore-instrumented-classes</id>
                        <goals>
                            <goal>restore-instrumented-classes</goal>
                        </goals>
                    </execution>
                    <execution>
                        <goals>
                            <goal>prepare-agent</goal>
                        </goals>
                        <configuration>
                            <excludes>
                                <exclude>*</exclude>
                            </excludes>
                        </configuration>
                    </execution>
                    <execution>
                        <id>report</id>
                        <phase>prepare-package</phase>
                        <goals>
                            <goal>report</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

</project>