blob: 227b48f9c738d4a016b47b0922e4e6c933ddc546 [file] [log] [blame]
ChrisC5e9feb22017-06-21 02:38:57 -07001<?xml version="1.0" encoding="UTF-8"?>
Determe, Sebastien (sd378r)e35744d2017-08-29 04:21:41 -07002<!--
3 ============LICENSE_START=======================================================
4 ONAP CLAMP
5 ================================================================================
TedHumphrey4aedf732019-08-13 15:56:33 +00006 Copyright (C) 2017-2019 AT&T Intellectual Property. All rights
Determe, Sebastien (sd378r)e35744d2017-08-29 04:21:41 -07007 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
ChrisC6c9759e2017-08-30 01:13:58 -070012
Determe, Sebastien (sd378r)e35744d2017-08-29 04:21:41 -070013 http://www.apache.org/licenses/LICENSE-2.0
ChrisC6c9759e2017-08-30 01:13:58 -070014
Determe, Sebastien (sd378r)e35744d2017-08-29 04:21:41 -070015 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 ===================================================================
Determe, Sebastien (sd378r)e35744d2017-08-29 04:21:41 -070022-->
sebdet101193d2019-09-05 18:25:59 +020023<project xmlns="http://maven.apache.org/POM/4.0.0"
24 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
25 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
26 <modelVersion>4.0.0</modelVersion>
27 <groupId>org.onap.clamp</groupId>
28 <artifactId>clds</artifactId>
sebdetbd8a7bf2019-10-21 11:01:10 +020029 <version>4.2.0-SNAPSHOT</version>
sebdet101193d2019-09-05 18:25:59 +020030 <name>clamp</name>
ChrisC5e9feb22017-06-21 02:38:57 -070031
sebdeta5243a42019-06-13 13:48:04 +020032
sebdet101193d2019-09-05 18:25:59 +020033 <parent>
34 <groupId>org.onap.oparent</groupId>
35 <artifactId>oparent</artifactId>
36 <version>2.0.0</version>
37 </parent>
Determe, Sebastien (sd378r)a66fe452017-08-08 06:42:49 -070038
sebdet101193d2019-09-05 18:25:59 +020039 <description>
40 This is the MAVEN project that builds everything for ONAP CLAMP.
41 Docker engine is normally requires to perfom all possible tasks (including integration tests)
42
43 It can build:
44 - The ONAP CLAMP JAR that contains CLAMP back-end code.
45 - The DOCKER images for:
46 * CLAMP backend (Java Spring)
47 * CLAMP frontend (Javscript React)
48 * The dashboard - Elastic search
49 * The dashboard - Logstash
50 * The dashboard - Kibana
Determe, Sebastien (sd378r)8bf33432017-08-08 02:49:33 -070051
sebdet101193d2019-09-05 18:25:59 +020052 It can test:
53 - The CLAMP backend, JAVA unit testing
54 - The CLAMP backend, JAVA integration tests (with Spring + docker mariadb database + docker policy/dcae emulator written in python)
55 - The CLAMP frontend, Javascrip tests (NodeJS(NPM) + JEST + Enzyme fro React)
56
57 The test coverage for dev's can be found after a "clean install" build in:
58 - Clamp backend: target/jacoco-dev.exec (unit tests + integration tests merged)
59 or separately target/coverage-reports/jacoco.exec and target/coverage-reports/jacoco-it.exec
60 - Clamp frontend: target/ui-react/coverage
Determe, Sebastien (sd378r)8bf33432017-08-08 02:49:33 -070061
sebdet101193d2019-09-05 18:25:59 +020062 Useful mvn commands:
63 - mvn clean install: Build Clamp backend JAR + unit tests + integration tests + NPM tests (+coverage for all)
64 - mvn clean install -DskipITs=true: Build Clamp backend JAR + unit tests + NPM tests (+coverage for all), it does not require a DOCKER engine
65 - mvn clean install -DskipTests -P docker: Build Clamp backend JAR + all docker images
Determe, Sebastien (sd378r)8bf33432017-08-08 02:49:33 -070066
sebdet101193d2019-09-05 18:25:59 +020067 To start CLAMP (Build it before):
68 - Use docker-compose file in ./extra/docker/clamp/docker-compose.yml
69 - Use the script located in ./extra/bin/start-backend.sh + start-frontend.sh
70 - Use your IDE to use the Jar or start NVM/NPM
Determe, Sebastien (sd378r)8bf33432017-08-08 02:49:33 -070071
sebdet101193d2019-09-05 18:25:59 +020072 </description>
ChrisCae04cf32018-02-05 05:21:59 -080073
sebdet101193d2019-09-05 18:25:59 +020074 <properties>
75 <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
76 <clamp.project.version>${project.version}</clamp.project.version>
77 <clamp.build.timestamp>${maven.build.timestamp}</clamp.build.timestamp>
78 <maven.compiler.source>1.8</maven.compiler.source>
79 <maven.compiler.target>1.8</maven.compiler.target>
80 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
81 <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
Determe, Sebastien (sd378r)8bf33432017-08-08 02:49:33 -070082
sebdet101193d2019-09-05 18:25:59 +020083 <eelf.core.version>1.0.0</eelf.core.version>
84 <camel.version>2.24.0</camel.version>
85 <springboot.version>2.1.5.RELEASE</springboot.version>
Determe, Sebastien (sd378r)8bf33432017-08-08 02:49:33 -070086
sebdet101193d2019-09-05 18:25:59 +020087 <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
88 <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
89 <sonar.jacoco.reportPath>${project.build.directory}/coverage-reports/jacoco.exec</sonar.jacoco.reportPath>
90 <sonar.jacoco.itReportPath>${project.build.directory}/coverage-reports/jacoco-it.exec</sonar.jacoco.itReportPath>
91 <sonar.jacoco.reportMissing.force.zero>true</sonar.jacoco.reportMissing.force.zero>
92 <sonar.projectVersion>${project.version}</sonar.projectVersion>
93 <!-- Enable language to disable javascript analysis -->
94 <!-- <sonar.language>java</sonar.language> -->
95 <!-- Parameters for Javascript coverage -->
sebdet337f3662019-09-06 18:11:51 +020096 <sonar.sources>src/main,${project.build.directory}/${ui.react.src}/src</sonar.sources>
sebdet101193d2019-09-05 18:25:59 +020097 <sonar.javascript.lcov.reportPaths>${project.build.directory}/${ui.react.src}/coverage/lcov.info</sonar.javascript.lcov.reportPaths>
Krysiak Adamcdfe48c2019-01-29 15:59:00 +010098
sebdet156d6ea2019-09-06 15:52:18 +020099 <sonar.exclusions>src/main/resources/**</sonar.exclusions>
xuegao4e2db352019-10-21 13:07:49 +0200100 <sonar.coverage.exclusions>src/main/resources/**,target/ui-react/src/**/*.test.js,target/ui-react/src/setupTests.js,src/main/docker/kibana/*.py</sonar.coverage.exclusions>
sebdet101193d2019-09-05 18:25:59 +0200101 <docker.push.registry>localhost:5000</docker.push.registry>
102 <docker.pull.registry>nexus3.onap.org:10001</docker.pull.registry>
103 <docker.skip.build>true</docker.skip.build>
104 <docker.skip.push>true</docker.skip.push>
105 <docker.skip.tag>true</docker.skip.tag>
106 <skip.staging.artifacts>false</skip.staging.artifacts>
107 <python.http.proxy.param />
108 <tomcat.version>9.0.20</tomcat.version>
109 <ui.react.src>ui-react</ui.react.src>
sebdet6b214fe2019-10-24 10:37:58 +0200110 <npm.publish.url>https://nexus3.onap.org/repository/npm.release/</npm.publish.url>
sebdet101193d2019-09-05 18:25:59 +0200111 </properties>
ChrisC5e9feb22017-06-21 02:38:57 -0700112
sebdet101193d2019-09-05 18:25:59 +0200113 <profiles>
114 <profile>
115 <id>without-test</id>
116 <activation>
117 <property>
118 <name>maven.test.skip</name>
119 <value>true</value>
120 </property>
121 </activation>
122 <properties>
123 <docker.skip.run>true</docker.skip.run>
124 <docker.skip>true</docker.skip>
125 </properties>
126 </profile>
127 <profile>
128 <id>without-IT-only</id>
129 <activation>
130 <property>
131 <name>skipITs</name>
132 <value>true</value>
133 </property>
134 </activation>
135 <properties>
136 <docker.skip.run>true</docker.skip.run>
137 <docker.skip>true</docker.skip>
138 </properties>
139 </profile>
140 <profile>
141 <id>without-IT-only2</id>
142 <activation>
143 <property>
144 <name>skipTests</name>
145 <value>true</value>
146 </property>
147 </activation>
148 <properties>
149 <docker.skip.run>true</docker.skip.run>
150 <docker.skip>true</docker.skip>
151 </properties>
152 </profile>
153 <profile>
154 <id>docker</id>
155 <properties>
156 <skip.staging.artifacts>true</skip.staging.artifacts>
157 <docker.skip.build>false</docker.skip.build>
158 <docker.skip.tag>false</docker.skip.tag>
159 <docker.skip.push>false</docker.skip.push>
160 <docker.skip>false</docker.skip>
161 </properties>
162 </profile>
163 </profiles>
Determe, Sebastien (sd378r)d3428d82018-06-26 15:05:55 +0200164
sebdet101193d2019-09-05 18:25:59 +0200165 <distributionManagement>
166 <repository>
167 <id>ecomp-releases</id>
168 <name>Clamp Release Repository</name>
169 <url>https://nexus.onap.org/content/repositories/releases/</url>
170 </repository>
171 <snapshotRepository>
172 <id>ecomp-snapshots</id>
173 <name>Clamp Snapshot Repository</name>
174 <url>https://nexus.onap.org/content/repositories/snapshots/</url>
175 </snapshotRepository>
176 <site>
177 <id>ecomp-site</id>
178 <url>dav:https://nexus.onap.org/content/sites/site/org/onap/clamp/${project.version}</url>
179 </site>
180 </distributionManagement>
ChrisC5e9feb22017-06-21 02:38:57 -0700181
sebdet101193d2019-09-05 18:25:59 +0200182 <repositories>
183 <repository>
184 <id>onap-public</id>
185 <name>onap-public</name>
186 <url>https://nexus.onap.org/content/repositories/public/</url>
187 <releases>
188 <enabled>true</enabled>
189 </releases>
190 <snapshots>
191 <enabled>false</enabled>
192 </snapshots>
193 </repository>
194 <repository>
195 <id>ecomp-releases</id>
196 <name>ONAP Release Repository</name>
197 <url>https://nexus.onap.org/content/repositories/releases/</url>
198 </repository>
199 <repository>
200 <id>ecomp-staging</id>
201 <name>ONAP Staging Repository</name>
202 <url>https://nexus.onap.org/content/repositories/staging/</url>
203 </repository>
204 <repository>
205 <id>ecomp-snapshots</id>
206 <name>ONAP Snapshot Repository</name>
207 <url>https://nexus.onap.org/content/repositories/snapshots/</url>
208 <snapshots>
209 <enabled>true</enabled>
210 </snapshots>
211 <releases>
212 <enabled>false</enabled>
213 </releases>
214 </repository>
215 <repository>
216 <id>central</id>
217 <url>http://repo1.maven.org/maven2/</url>
218 </repository>
219 </repositories>
220 <pluginRepositories>
221 <pluginRepository>
222 <id>onap-public</id>
223 <name>onap-public</name>
224 <url>https://nexus.onap.org/content/repositories/public/</url>
225 <releases>
226 <enabled>true</enabled>
227 </releases>
228 <snapshots>
229 <enabled>false</enabled>
230 </snapshots>
231 </pluginRepository>
232 <pluginRepository>
233 <id>central</id>
234 <url>http://repo1.maven.org/maven2/</url>
235 </pluginRepository>
236 </pluginRepositories>
ChrisC5e9feb22017-06-21 02:38:57 -0700237
sebdet101193d2019-09-05 18:25:59 +0200238 <dependencyManagement>
Determe, Sebastien (sd378r)b4f7cb62017-11-16 13:27:22 +0100239 <dependencies>
sebdet101193d2019-09-05 18:25:59 +0200240 <!-- Spring Boot BOM -->
Piotr Darosz6eb37422019-03-08 14:50:29 +0100241 <dependency>
sebdet101193d2019-09-05 18:25:59 +0200242 <groupId>org.springframework.boot</groupId>
243 <artifactId>spring-boot-dependencies</artifactId>
244 <version>${springboot.version}</version>
245 <type>pom</type>
246 <scope>import</scope>
Piotr Darosz6eb37422019-03-08 14:50:29 +0100247 </dependency>
sebdet101193d2019-09-05 18:25:59 +0200248 <!-- Camel BOM -->
Piotr Darosz6eb37422019-03-08 14:50:29 +0100249 <dependency>
sebdet101193d2019-09-05 18:25:59 +0200250 <groupId>org.apache.camel</groupId>
251 <artifactId>camel-spring-boot-dependencies</artifactId>
252 <version>${camel.version}</version>
253 <type>pom</type>
254 <scope>import</scope>
Piotr Darosz6eb37422019-03-08 14:50:29 +0100255 </dependency>
sebdet101193d2019-09-05 18:25:59 +0200256 </dependencies>
257 </dependencyManagement>
258
259 <dependencies>
260 <dependency>
261 <groupId>org.apache.xmlgraphics</groupId>
262 <artifactId>batik-svggen</artifactId>
263 <version>1.11</version>
264 </dependency>
265 <dependency>
266 <groupId>org.apache.xmlgraphics</groupId>
267 <artifactId>batik-svg-dom</artifactId>
268 <version>1.11</version>
269 </dependency>
270 <dependency>
271 <groupId>org.apache.xmlgraphics</groupId>
272 <artifactId>batik-transcoder</artifactId>
273 <version>1.11</version>
274 </dependency>
275 <dependency>
276 <groupId>com.att.eelf</groupId>
277 <artifactId>eelf-core</artifactId>
278 <version>${eelf.core.version}</version>
279 </dependency>
280 <dependency>
281 <groupId>org.codehaus.janino</groupId>
282 <artifactId>janino</artifactId>
283 <version>3.0.8</version>
284 </dependency>
285 <dependency>
286 <groupId>org.apache.tomcat.embed</groupId>
287 <artifactId>tomcat-embed-core</artifactId>
288 <version>${tomcat.version}</version>
289 </dependency>
290 <dependency>
291 <groupId>org.apache.tomcat.embed</groupId>
292 <artifactId>tomcat-embed-el</artifactId>
293 <version>${tomcat.version}</version>
294 </dependency>
295 <dependency>
296 <groupId>org.apache.tomcat.embed</groupId>
297 <artifactId>tomcat-embed-websocket</artifactId>
298 <version>${tomcat.version}</version>
299 </dependency>
300 <dependency>
301 <groupId>org.apache.tomcat</groupId>
302 <artifactId>tomcat-annotations-api</artifactId>
303 <version>${tomcat.version}</version>
304 </dependency>
305 <!-- For CAMEL -->
306 <dependency>
307 <groupId>org.apache.camel</groupId>
308 <artifactId>camel-http4-starter</artifactId>
309 </dependency>
310 <dependency>
311 <groupId>org.apache.camel</groupId>
312 <artifactId>camel-spring-boot-starter</artifactId>
313 </dependency>
314 <dependency>
315 <groupId>org.apache.camel</groupId>
316 <artifactId>camel-jaxb-starter</artifactId>
317 </dependency>
318 <dependency>
319 <groupId>org.apache.camel</groupId>
320 <artifactId>camel-servlet-starter</artifactId>
321 </dependency>
322 <dependency>
323 <groupId>org.apache.camel</groupId>
324 <artifactId>camel-gson-starter</artifactId>
325 </dependency>
326 <dependency>
327 <groupId>org.apache.camel</groupId>
328 <artifactId>camel-swagger-java-starter</artifactId>
329 <exclusions>
330 <exclusion>
331 <groupId>javax.ws.rs</groupId>
332 <artifactId>jsr311-api</artifactId>
333 </exclusion>
334 <exclusion>
335 <groupId>org.slf4j</groupId>
336 <artifactId>slf4j-ext</artifactId>
337 </exclusion>
338 <exclusion>
339 <groupId>com.fasterxml.jackson.core</groupId>
340 <artifactId>jackson-databind</artifactId>
341 </exclusion>
342 </exclusions>
343 </dependency>
344 <dependency>
345 <groupId>javax.xml.bind</groupId>
346 <artifactId>jaxb-api</artifactId>
347 <version>2.3.0</version>
348 </dependency>
349 <dependency>
350 <groupId>org.glassfish.jersey.core</groupId>
351 <artifactId>jersey-common</artifactId>
352 <version>2.27</version>
353 </dependency>
354 <!-- Spring famework -->
355 <dependency>
356 <groupId>org.springframework.boot</groupId>
357 <artifactId>spring-boot-starter-web</artifactId>
358 <exclusions>
359 <exclusion>
360 <groupId>org.springframework.boot</groupId>
361 <artifactId>spring-boot-starter-json</artifactId>
362 </exclusion>
363 </exclusions>
364 </dependency>
365 <dependency>
366 <groupId>org.springframework.boot</groupId>
367 <artifactId>spring-boot-starter-tomcat</artifactId>
368 </dependency>
369 <dependency>
370 <groupId>org.springframework</groupId>
371 <artifactId>spring-jdbc</artifactId>
372 </dependency>
373 <dependency>
374 <groupId>org.springframework.boot</groupId>
375 <artifactId>spring-boot-starter-security</artifactId>
376 </dependency>
377 <dependency>
378 <groupId>org.springframework.boot</groupId>
379 <artifactId>spring-boot-autoconfigure</artifactId>
380 </dependency>
381 <dependency>
382 <groupId>org.springframework.boot</groupId>
383 <artifactId>spring-boot-starter-test</artifactId>
384 <scope>test</scope>
385 <exclusions>
386 <exclusion>
387 <groupId>com.vaadin.external.google</groupId>
388 <artifactId>android-json</artifactId>
389 </exclusion>
390 </exclusions>
391 </dependency>
392 <dependency>
393 <groupId>org.springframework.boot</groupId>
394 <artifactId>spring-boot-starter-data-jpa</artifactId>
395 </dependency>
396 <!-- Others dependencies -->
397 <dependency>
398 <groupId>org.onap.aaf.authz</groupId>
399 <artifactId>aaf-cadi-aaf</artifactId>
sebdetdcc4bdc2019-10-15 14:04:00 +0200400 <version>2.1.15</version>
sebdet101193d2019-09-05 18:25:59 +0200401 <exclusions>
402 <exclusion>
403 <groupId>javax.servlet</groupId>
404 <artifactId>servlet-api</artifactId>
405 </exclusion>
406 </exclusions>
407 </dependency>
408 <dependency>
409 <groupId>ch.qos.logback</groupId>
410 <artifactId>logback-core</artifactId>
411 <version>1.2.3</version>
412 </dependency>
413 <dependency>
414 <groupId>ch.qos.logback</groupId>
415 <artifactId>logback-classic</artifactId>
416 <version>1.2.3</version>
417 </dependency>
418 <dependency>
419 <groupId>commons-dbcp</groupId>
420 <artifactId>commons-dbcp</artifactId>
421 <version>1.4</version>
422 </dependency>
423 <dependency>
424 <groupId>commons-io</groupId>
425 <artifactId>commons-io</artifactId>
426 <version>2.6</version>
427 </dependency>
428 <dependency>
429 <groupId>com.googlecode.json-simple</groupId>
430 <artifactId>json-simple</artifactId>
431 <version>1.1.1</version>
432 </dependency>
433 <dependency>
434 <groupId>org.apache.commons</groupId>
435 <artifactId>commons-vfs2</artifactId>
436 <version>2.2</version>
437 </dependency>
438 <dependency>
439 <groupId>joda-time</groupId>
440 <artifactId>joda-time</artifactId>
441 </dependency>
442 <dependency>
443 <groupId>org.slf4j</groupId>
444 <artifactId>slf4j-api</artifactId>
445 </dependency>
446 <dependency>
447 <groupId>javax.ws.rs</groupId>
448 <artifactId>javax.ws.rs-api</artifactId>
449 <version>2.0</version>
450 </dependency>
451 <dependency>
452 <groupId>junit</groupId>
453 <artifactId>junit</artifactId>
454 </dependency>
455 <dependency>
456 <groupId>javax.transaction</groupId>
457 <artifactId>jta</artifactId>
458 <version>1.1</version>
459 </dependency>
460 <dependency>
461 <groupId>javax.persistence</groupId>
462 <artifactId>persistence-api</artifactId>
463 <version>1.0.2</version>
464 </dependency>
465 <dependency>
sebdet101193d2019-09-05 18:25:59 +0200466 <groupId>org.apache.commons</groupId>
467 <artifactId>commons-csv</artifactId>
468 <version>1.3</version>
469 </dependency>
470 <!-- Other dependencies to fix nexus IQ reported vulnerabilities -->
471 <dependency>
472 <groupId>org.codehaus.plexus</groupId>
473 <artifactId>plexus-utils</artifactId>
474 <version>3.0.24</version>
475 </dependency>
476 <dependency>
477 <groupId>org.jboss.spec.javax.ws.rs</groupId>
478 <artifactId>jboss-jaxrs-api_2.0_spec</artifactId>
479 <version>1.0.1.Final</version>
480 </dependency>
481 <dependency>
482 <groupId>com.google.guava</groupId>
483 <artifactId>guava</artifactId>
484 <version>27.0-jre</version>
485 </dependency>
sebdete77e0ff2019-09-09 13:18:35 +0200486 <dependency>
487 <groupId>commons-codec</groupId>
488 <artifactId>commons-codec</artifactId>
489 <version>1.13</version>
490 </dependency>
sebdet101193d2019-09-05 18:25:59 +0200491 <!-- Remove the MYSQL connector and replace it by Mariadb -->
492 <dependency>
493 <groupId>org.mariadb.jdbc</groupId>
494 <artifactId>mariadb-java-client</artifactId>
495 <version>2.2.1</version>
496 </dependency>
497 <!-- For SDC Controller -->
498 <dependency>
499 <groupId>org.onap.sdc.sdc-distribution-client</groupId>
500 <artifactId>sdc-distribution-client</artifactId>
501 <version>1.3.0</version>
502 </dependency>
503 <dependency>
504 <groupId>org.onap.sdc.sdc-tosca</groupId>
505 <artifactId>sdc-tosca</artifactId>
506 <version>1.5.1</version>
507 </dependency>
508 <!-- TESTING -->
509 <dependency>
510 <groupId>org.assertj</groupId>
511 <artifactId>assertj-core</artifactId>
512 <version>3.10.0</version>
513 <scope>test</scope>
514 </dependency>
515 <dependency>
516 <groupId>org.mockito</groupId>
517 <artifactId>mockito-core</artifactId>
518 <version>1.10.19</version>
519 <scope>test</scope>
520 </dependency>
521 </dependencies>
522
523 <build>
524 <finalName>clamp</finalName>
525
526 <testResources>
527 <testResource>
528 <directory>src/test/resources</directory>
529 <excludes>
530 <exclude>**/*.jks</exclude>
531 <exclude>**/*.csar</exclude>
532 </excludes>
533 <filtering>true</filtering>
534 </testResource>
535 <testResource>
536 <directory>src/test/resources/https</directory>
537 <includes>
538 <include>**.jks</include>
539 </includes>
540 <filtering>false</filtering>
541 <targetPath>https</targetPath>
542 </testResource>
543 <testResource>
544 <directory>src/test/resources/example/sdc</directory>
545 <includes>
546 <include>**.csar</include>
547 </includes>
548 <filtering>false</filtering>
549 <targetPath>example/sdc</targetPath>
550 </testResource>
551 </testResources>
552 <resources>
553 <!-- For AAF folder maven should not try to filter Keystores/Truststores ... Otherwise
554 they will be broken and unreadable -->
555 <resource>
556 <directory>src/main/resources</directory>
557 <filtering>true</filtering>
558 <excludes>
559 <exclude>clds/aaf/**</exclude>
560 </excludes>
561 </resource>
562 <resource>
563 <directory>src/main/resources</directory>
564 <filtering>false</filtering>
565 <includes>
566 <include>clds/aaf/**</include>
567 </includes>
568 </resource>
569 <resource>
570 <directory>${ui.react.src}</directory>
571 <includes>
572 <include>src/**</include>
573 <include>public/**</include>
574 <include>package.json</include>
575 <include>package-lock.json</include>
576 </includes>
577 <filtering>true</filtering>
578 <targetPath>${project.build.directory}/${ui.react.src}</targetPath>
579 </resource>
580 </resources>
581
582 <plugins>
583 <plugin>
584 <groupId>de.jpdigital</groupId>
585 <artifactId>hibernate52-ddl-maven-plugin</artifactId>
586 <version>2.2.0</version>
587 <dependencies>
588 <dependency>
Determe, Sebastien (sd378r)f7855162018-04-27 14:02:39 +0200589 <groupId>javax.xml.bind</groupId>
590 <artifactId>jaxb-api</artifactId>
591 <version>2.3.0</version>
sebdet101193d2019-09-05 18:25:59 +0200592 </dependency>
593 </dependencies>
594 <executions>
595 <execution>
596 <phase>process-classes</phase>
597 <goals>
598 <goal>gen-ddl</goal>
599 </goals>
sebdete4422002018-10-16 17:47:54 +0200600 <configuration>
sebdet101193d2019-09-05 18:25:59 +0200601 <packages>
602 <param>org.onap.clamp.dao.model</param>
603 </packages>
604 <dialects>
605 <param>MARIADB53</param>
606 </dialects>
607 <outputDirectory>${project.basedir}/extra/sql/bulkload/</outputDirectory>
608 <outputFileNameSuffix>create-tables</outputFileNameSuffix>
609 <!-- <createDropStatements>true</createDropStatements> -->
610 <omitDialectFromFileName>true</omitDialectFromFileName>
sebdete4422002018-10-16 17:47:54 +0200611 </configuration>
sebdet101193d2019-09-05 18:25:59 +0200612 </execution>
613 </executions>
614
615 </plugin>
616 <!-- Read the swagger.json file and the definition from SwaggerConfig.java; generate
617 a list of .adoc files containing the APIs info in more structured way -->
618 <plugin>
619 <groupId>io.github.swagger2markup</groupId>
620 <artifactId>swagger2markup-maven-plugin</artifactId>
621 <version>1.3.3</version>
622 <dependencies>
623 <dependency>
624 <groupId>io.github.swagger2markup</groupId>
625 <artifactId>swagger2markup-import-files-ext</artifactId>
626 <version>1.3.3</version>
627 </dependency>
628 <dependency>
629 <groupId>io.github.swagger2markup</groupId>
630 <artifactId>swagger2markup-spring-restdocs-ext</artifactId>
631 <version>1.3.3</version>
632 </dependency>
633 </dependencies>
634 <configuration>
635 <swaggerInput>${project.basedir}/docs/swagger/swagger.json</swaggerInput>
636 <outputDir>${project.build.directory}/asciidoc/generated</outputDir>
637 <config>
638 <swagger2markup.markupLanguage>ASCIIDOC</swagger2markup.markupLanguage>
639 </config>
640 </configuration>
641 <executions>
642 <execution>
643 <phase>post-integration-test</phase>
644 <goals>
645 <goal>convertSwagger2markup</goal>
646 </goals>
647 </execution>
648 </executions>
649 </plugin>
650
651 <!-- Run the generated asciidoc through Asciidoctor to generate other documentation
652 types, such as PDFs or HTML5 -->
653 <plugin>
654 <groupId>org.asciidoctor</groupId>
655 <artifactId>asciidoctor-maven-plugin</artifactId>
656 <version>1.5.7.1</version>
657 <dependencies>
658 <dependency>
659 <groupId>org.asciidoctor</groupId>
660 <artifactId>asciidoctorj-pdf</artifactId>
661 <version>1.5.0-alpha.10.1</version>
662 </dependency>
663 </dependencies>
664 <configuration>
665 <sourceDirectory>${project.basedir}/src/main/resources/asciidoc</sourceDirectory>
666 <sourceDocumentName>swagger.adoc</sourceDocumentName>
667 <attributes>
668 <doctype>book</doctype>
669 <toc>left</toc>
670 <toclevels>3</toclevels>
671 <numbered />
672 <hardbreaks />
673 <sectlinks />
674 <sectanchors />
675 <generated>${project.build.directory}/asciidoc/generated</generated>
676 </attributes>
677 </configuration>
678
679 <executions>
680 <execution>
681 <id>output-html</id>
682 <phase>post-integration-test</phase>
683 <goals>
684 <goal>process-asciidoc</goal>
685 </goals>
686 <configuration>
687 <backend>html5</backend>
688 <outputDirectory>${project.basedir}/docs/swagger</outputDirectory>
689 <outputDirectory>${project.basedir}/src/main/resources/META-INF/resources/</outputDirectory>
690 </configuration>
691 </execution>
692 <execution>
693 <id>output-pdf</id>
694 <phase>post-integration-test</phase>
695 <goals>
696 <goal>process-asciidoc</goal>
697 </goals>
698 <configuration>
699 <backend>pdf</backend>
700 <outputDirectory>${project.basedir}/docs/swagger</outputDirectory>
701 </configuration>
702 </execution>
703 </executions>
704 </plugin>
705 <plugin>
706 <groupId>org.codehaus.groovy.maven</groupId>
707 <artifactId>gmaven-plugin</artifactId>
708 <version>1.0</version>
709 <executions>
710 <execution>
711 <phase>validate</phase>
712 <goals>
713 <goal>execute</goal>
714 </goals>
715 <configuration>
716 <source>${project.basedir}/src/main/script/TagVersion.groovy</source>
717 </configuration>
718 </execution>
719 </executions>
720 </plugin>
721 <plugin>
722 <groupId>org.apache.maven.plugins</groupId>
723 <artifactId>maven-jar-plugin</artifactId>
724 <version>3.0.2</version>
725 <executions>
726 <execution>
727 <id>jar-with-only-classes</id>
728 <phase>package</phase>
729 <goals>
730 <goal>jar</goal>
731 </goals>
732 <configuration>
733 <classifier>classes</classifier>
734 <includes>
735 <include>org/**</include>
736 </includes>
737 </configuration>
738 </execution>
739 </executions>
740 </plugin>
741 <plugin>
742 <groupId>org.codehaus.mojo</groupId>
743 <artifactId>build-helper-maven-plugin</artifactId>
744 <version>3.0.0</version>
745 <executions>
746 <execution>
747 <goals>
748 <goal>attach-artifact</goal>
749 </goals>
750 <phase>package</phase>
751 <configuration>
752 <artifacts>
753 <artifact>
754 <file>${project.build.directory}/clamp-classes.jar</file>
755 <type>jar</type>
756 <classifier>classes</classifier>
757 </artifact>
758 </artifacts>
759 </configuration>
760 </execution>
761 <execution>
762 <id>reserve-port-for-tests</id>
763 <phase>process-resources</phase>
764 <goals>
765 <goal>reserve-network-port</goal>
766 </goals>
767 <configuration>
768 <portNames>
769 <portName>docker.mariadb.port.host</portName>
770 <portName>docker.http-cache.port.host</portName>
771 <portName>clamp.it.tests.http-redirected</portName>
772 <portName>clamp.it.tests.https</portName>
773 <portName>clamp.it.tests.http</portName>
774 </portNames>
775 </configuration>
776 </execution>
777 </executions>
778 </plugin>
779
780 <plugin>
781 <groupId>org.springframework.boot</groupId>
782 <artifactId>spring-boot-maven-plugin</artifactId>
783 <!-- Temporary fix -->
784 <version>1.5.13.RELEASE</version>
785 <!-- <version>${springboot.version}</version> -->
786 <executions>
787 <execution>
788 <goals>
789 <goal>repackage</goal>
790 </goals>
791 <phase>package</phase>
792 </execution>
793 </executions>
794 </plugin>
795 <plugin>
796 <groupId>org.apache.maven.plugins</groupId>
797 <artifactId>maven-surefire-plugin</artifactId>
798 <version>2.22.1</version>
799 <configuration>
800 <forkCount>1C</forkCount>
801 <reuseForks>true</reuseForks>
802 <useSystemClassLoader>false</useSystemClassLoader>
803 <argLine>${surefireArgLine}</argLine>
804 </configuration>
805 </plugin>
806
807 <plugin>
808 <groupId>org.apache.maven.plugins</groupId>
809 <artifactId>maven-failsafe-plugin</artifactId>
810 <version>2.22.1</version>
811 <executions>
812 <execution>
813 <id>integration-tests</id>
814 <goals>
815 <goal>integration-test</goal>
816 <goal>verify</goal>
817 </goals>
818 <configuration>
819 <additionalClasspathElements>
820 <additionalClasspathElement>${project.build.directory}/classes</additionalClasspathElement>
821 </additionalClasspathElements>
822 <includes>
823 <include>**/*ItCase.java</include>
824 </includes>
825 <forkCount>1</forkCount>
826 <reuseForks>true</reuseForks>
827 <useSystemClassLoader>false</useSystemClassLoader>
828 <argLine>${failsafeArgLine}</argLine>
829 </configuration>
830 </execution>
831 </executions>
sebdet101193d2019-09-05 18:25:59 +0200832 </plugin>
833 <plugin>
834 <groupId>io.fabric8</groupId>
835 <artifactId>docker-maven-plugin</artifactId>
836 <version>0.27.2</version>
837 <dependencies>
838 <dependency>
839 <groupId>org.apache.httpcomponents</groupId>
840 <artifactId>httpclient</artifactId>
841 <version>4.5.5</version>
842 </dependency>
843 </dependencies>
844 <configuration>
845 <verbose>true</verbose>
846 <apiVersion>1.35</apiVersion>
847 <images>
848 <image>
849 <name>library/mariadb:10.3.12</name>
850 <alias>mariadb</alias>
851 <run>
852 <env>
853 <MYSQL_ROOT_PASSWORD>strong_pitchou</MYSQL_ROOT_PASSWORD>
854 </env>
855 <hostname>mariadb</hostname>
856 <volumes>
857 <bind>
sebdetfdfde212019-09-12 10:59:15 +0200858 <volume>${project.basedir}/extra/sql/:/docker-entrypoint-initdb.d:rw</volume>
sebdet101193d2019-09-05 18:25:59 +0200859 <volume>${project.basedir}/extra/docker/mariadb/conf1:/etc/mysql/conf.d</volume>
860 </bind>
861 </volumes>
862 <wait>
863 <log>socket: '/var/run/mysqld/mysqld.sock' port: 3306 mariadb.org binary distribution</log>
864 <time>600000</time>
sebdetfdfde212019-09-12 10:59:15 +0200865 <exec>
866 <preStop>/docker-entrypoint-initdb.d/dump/backup-data-only.sh</preStop>
867 </exec>
sebdet101193d2019-09-05 18:25:59 +0200868 </wait>
869 <ports>
870 <port>${docker.mariadb.port.host}:3306</port>
871 </ports>
872 </run>
873 </image>
874 <image>
875 <name>library/python:2-slim</name>
876 <alias>python</alias>
877 <run>
878 <hostname>python</hostname>
879 <volumes>
880 <bind>
881 <volume>${project.basedir}/src/test/resources/http-cache/:/usr/src/http-cache-app</volume>
882 <volume>${project.basedir}/src/test/resources/http-cache/example/:/usr/src/http-cache-app/data-cache</volume>
883 </bind>
884 </volumes>
885 <wait>
886 <tcp>
887 <ports>
888 <port>8080</port>
889 </ports>
890 <mode>direct</mode>
891 </tcp>
892 <time>120000</time>
893 </wait>
894 <ports>
895 <port>${docker.http-cache.port.host}:8080</port>
896 </ports>
897 <workingDir>/usr/src/http-cache-app</workingDir>
898 <cmd>
899 <shell>./start_http_cache.sh ${python.http.proxy.param}
900 --python_proxyaddress=localhost:${docker.http-cache.port.host}</shell>
901 </cmd>
902 </run>
903 </image>
904 <image>
905 <name>onap/clamp-backend</name>
906 <alias>onap-clamp-backend</alias>
907 <run>
908 <skip>true</skip>
909 </run>
910 <build>
911 <cleanup>true</cleanup>
912 <tags>
913 <tag>latest</tag>
914 <tag>${project.docker.latesttagtimestamp.version}</tag>
915 <tag>${project.docker.latesttag.version}</tag>
916 </tags>
917 <!-- A relative path is looked up in ${project.basedir}/src/main/docker by
918 default -->
919 <dockerFile>backend/Dockerfile</dockerFile>
920 <assembly>
921 <descriptor>backend/backend-files.xml</descriptor>
922 <name>onap-clamp-backend</name>
923 </assembly>
924 </build>
925 </image>
926 <image>
927 <name>onap/clamp-frontend</name>
928 <alias>onap-clamp-frontend</alias>
929 <run>
930 <skip>true</skip>
931 </run>
932 <build>
933 <cleanup>true</cleanup>
934 <tags>
935 <tag>latest</tag>
936 <tag>${project.docker.latesttagtimestamp.version}</tag>
937 <tag>${project.docker.latesttag.version}</tag>
938 </tags>
939 <!-- A relative path is looked up in ${project.basedir}/src/main/docker by
940 default -->
941 <dockerFile>frontend/Dockerfile</dockerFile>
942 <assembly>
943 <descriptor>frontend/frontend-files.xml</descriptor>
944 <name>onap-clamp-frontend</name>
945 </assembly>
946 </build>
947 </image>
948 <image>
sebdet101193d2019-09-05 18:25:59 +0200949 <name>onap/clamp-dashboard-logstash</name>
950 <alias>onap-clamp-dashboard-logstash</alias>
951 <run>
952 <skip>true</skip>
953 </run>
954 <build>
955 <cleanup>true</cleanup>
956 <tags>
957 <tag>latest</tag>
958 <tag>${project.docker.latesttagtimestamp.version}</tag>
959 <tag>${project.docker.latesttag.version}</tag>
960 </tags>
961 <dockerFile>logstash/Dockerfile</dockerFile>
962 </build>
963 </image>
964 <image>
965 <name>onap/clamp-dashboard-kibana</name>
966 <alias>onap-clamp-dashboard-kibana</alias>
967 <run>
968 <skip>true</skip>
969 </run>
970 <build>
971 <cleanup>true</cleanup>
972 <tags>
973 <tag>latest</tag>
974 <tag>${project.docker.latesttagtimestamp.version}</tag>
975 <tag>${project.docker.latesttag.version}</tag>
976 </tags>
977 <dockerFile>kibana/Dockerfile</dockerFile>
978 </build>
979 </image>
980 </images>
981 </configuration>
982
983 <executions>
984 <execution>
985 <id>generate-images</id>
986 <phase>install</phase>
987 <goals>
988 <goal>build</goal>
989 </goals>
990 </execution>
991 <execution>
992 <id>push-images</id>
993 <phase>deploy</phase>
994 <goals>
995 <goal>push</goal>
996 </goals>
997 </execution>
998 <execution>
999 <id>docker-start-for-it</id>
1000 <phase>pre-integration-test</phase>
1001 <goals>
1002 <goal>start</goal>
1003 </goals>
1004 </execution>
1005 <execution>
1006 <id>docker-stop-for-it</id>
1007 <phase>post-integration-test</phase>
1008 <goals>
1009 <goal>stop</goal>
1010 </goals>
1011 </execution>
1012 </executions>
1013 </plugin>
1014
1015 <plugin>
1016 <groupId>org.jacoco</groupId>
1017 <artifactId>jacoco-maven-plugin</artifactId>
1018 <version>0.8.2</version>
1019 <configuration>
1020 <dumpOnExit>true</dumpOnExit>
1021 <append>true</append>
1022 <includes>
1023 <include>org.onap.clamp.*</include>
1024 </includes>
1025 </configuration>
1026 <executions>
1027 <execution>
1028 <id>pre-unit-test</id>
1029 <goals>
1030 <goal>prepare-agent</goal>
1031 </goals>
1032 <configuration>
1033 <destFile>${project.build.directory}/coverage-reports/jacoco.exec</destFile>
1034 <propertyName>surefireArgLine</propertyName>
1035 <!-- <append>true</append> -->
1036 </configuration>
1037 </execution>
1038 <execution>
1039 <id>pre-integration-test</id>
1040 <phase>pre-integration-test</phase>
1041 <goals>
1042 <goal>prepare-agent</goal>
1043 </goals>
1044 <configuration>
1045 <destFile>${project.build.directory}/coverage-reports/jacoco-it.exec</destFile>
1046 <propertyName>failsafeArgLine</propertyName>
1047 <!-- <append>true</append> -->
1048 </configuration>
1049 </execution>
1050 <execution>
1051 <goals>
1052 <goal>merge</goal>
1053 </goals>
1054 <phase>post-integration-test</phase>
1055 <configuration>
1056 <fileSets>
1057 <fileSet
1058 implementation="org.apache.maven.shared.model.fileset.FileSet">
1059 <directory>${project.build.directory}/coverage-reports</directory>
1060 <includes>
1061 <include>*.exec</include>
1062 </includes>
1063 </fileSet>
1064 </fileSets>
1065 <destFile>${project.build.directory}/jacoco-dev.exec</destFile>
1066 </configuration>
1067 </execution>
1068 </executions>
1069 </plugin>
1070
1071 <!-- This plugin will be useful when we will have multi-modules project -->
1072 <plugin>
1073 <groupId>org.codehaus.mojo</groupId>
1074 <artifactId>versions-maven-plugin</artifactId>
1075 <version>1.3.1</version>
1076 </plugin>
1077
1078 <plugin>
1079 <groupId>com.github.eirslett</groupId>
1080 <artifactId>frontend-maven-plugin</artifactId>
1081 <version>1.8.0</version>
1082 <configuration>
1083 <installDirectory>${project.build.directory}/${ui.react.src}</installDirectory>
1084 <workingDirectory>${project.build.directory}/${ui.react.src}</workingDirectory>
1085 </configuration>
1086 <executions>
1087 <execution>
1088 <id>install_node_and_npm</id>
1089 <goals>
1090 <goal>install-node-and-npm</goal>
1091 </goals>
1092 <phase>generate-sources</phase>
1093 <configuration>
sebdet81f5cab2019-11-06 11:40:46 +01001094 <nodeVersion>v12.13.0</nodeVersion>
1095 <npmVersion>6.13.0</npmVersion>
sebdet101193d2019-09-05 18:25:59 +02001096 </configuration>
1097 </execution>
1098 <execution>
1099 <id>npm_install</id>
1100 <goals>
1101 <goal>npm</goal>
1102 </goals>
1103 <phase>compile</phase>
1104 <configuration>
sebdet996071f2019-10-25 13:25:57 +02001105 <arguments>install</arguments>
sebdet101193d2019-09-05 18:25:59 +02001106 </configuration>
1107 </execution>
1108 <execution>
1109 <id>npm_test</id>
1110 <goals>
1111 <goal>npm</goal>
1112 </goals>
1113 <phase>test</phase>
1114 <configuration>
1115 <arguments>run-script test:coverage</arguments>
1116 </configuration>
1117 </execution>
1118 <execution>
1119 <id>npm_publish</id>
1120 <goals>
1121 <goal>npm</goal>
1122 </goals>
1123 <phase>deploy</phase>
1124 <configuration>
sebdet4c272742019-10-23 14:40:31 +02001125 <arguments>run-script publish</arguments>
sebdet101193d2019-09-05 18:25:59 +02001126 </configuration>
1127 </execution>
1128 </executions>
1129 </plugin>
1130 </plugins>
1131 </build>
ChrisC5e9feb22017-06-21 02:38:57 -07001132</project>