2 ============LICENSE_START=======================================================
4 ================================================================================
5 Copyright © 2017-2018 AT&T Intellectual Property. All rights reserved.
6 Copyright © 2017-2018 Amdocs
7 ================================================================================
8 Licensed under the Apache License, Version 2.0 (the "License");
9 you may not use this file except in compliance with the License.
10 You may obtain a copy of the License at
12 http://www.apache.org/licenses/LICENSE-2.0
14 Unless required by applicable law or agreed to in writing, software
15 distributed under the License is distributed on an "AS IS" BASIS,
16 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 See the License for the specific language governing permissions and
18 limitations under the License.
19 ============LICENSE_END=========================================================
21 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
22 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
23 <modelVersion>4.0.0</modelVersion>
26 <groupId>org.springframework.boot</groupId>
27 <artifactId>spring-boot-starter-parent</artifactId>
28 <version>1.5.21.RELEASE</version>
31 <groupId>org.onap.aai.data-router</groupId>
32 <artifactId>data-router</artifactId>
33 <version>1.6.1-SNAPSHOT</version>
34 <name>aai-data-router</name>
37 <java.version>1.8</java.version>
38 <camel-spring-boot.version>2.21.1</camel-spring-boot.version>
39 <absoluteDistFilesRoot>/appl/${project.artifactId}</absoluteDistFilesRoot>
40 <!-- For NO Versioning, REMOVE the /${project.version} from the <distFilesRoot>
41 property, below. PLEASE, NOTE: If your ${project.version} is a "-SNAPSHOT"
42 version, THIS will be used as your directory structure. If you do NOT want
43 this, simply remove the "-SNAPSHOT" from your <version> declaration at the
45 <distFilesRoot>/appl/${project.artifactId}/${project.version}</distFilesRoot>
46 <!-- For SOA Cloud Installation -->
47 <installOwnerUser>aaiadmin</installOwnerUser>
48 <installOwnerGroup>aaiadmin</installOwnerGroup>
49 <ownerManagementGroup>com.att.csid.lab</ownerManagementGroup>
50 <version.aai-schema>1.6.0</version.aai-schema>
52 <!-- docker related properties -->
53 <docker.fabric.version>0.28.0</docker.fabric.version>
54 <aai.docker.version>1.0.0</aai.docker.version>
55 <aai.build.directory>${project.build.directory}/${project.artifactId}-build/
56 </aai.build.directory>
57 <aai.docker.namespace>onap</aai.docker.namespace>
58 <aai.base.image>alpine</aai.base.image>
59 <aai.base.image.version>1.6.0</aai.base.image.version>
61 <!-- Port Selection. A value of 0 will allow for dynamic port selection.
62 For local testing, you may choose to hardcode this value to something like
64 <serverPort>0</serverPort>
65 <sslport>9502</sslport>
67 <testRouteOffer>workstation</testRouteOffer>
68 <testEnv>DEV</testEnv>
69 <checkstyle.config.location>google_checks.xml</checkstyle.config.location>
70 <nexusproxy>https://nexus.onap.org</nexusproxy>
71 <!-- Sonar Properties -->
72 <sonar.language>java</sonar.language>
73 <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
74 <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
75 <sonar.jacoco.reportPath>${project.build.directory}/coverage-reports/jacoco.exec</sonar.jacoco.reportPath>
76 <sonar.jacoco.reportMissing.force.zero>false</sonar.jacoco.reportMissing.force.zero>
77 <sonar.projectVersion>${project.version}</sonar.projectVersion>
78 <logback.version>1.2.3</logback.version>
79 <version.com.google.guava>16.0.1</version.com.google.guava>
80 <shemaUnpackVersion>onap</shemaUnpackVersion>
81 <jacoco.line.coverage.limit>0.58</jacoco.line.coverage.limit>
82 <!-- This will be used for the docker images as the default format of maven build has issues -->
83 <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
88 <groupId>ch.qos.logback</groupId>
89 <artifactId>logback-core</artifactId>
90 <version>${logback.version}</version>
93 <groupId>ch.qos.logback</groupId>
94 <artifactId>logback-classic</artifactId>
95 <version>${logback.version}</version>
98 <groupId>ch.qos.logback</groupId>
99 <artifactId>logback-access</artifactId>
100 <version>${logback.version}</version>
103 <groupId>org.apache.camel</groupId>
104 <artifactId>camel-spring-boot-starter</artifactId>
107 <groupId>org.apache.camel</groupId>
108 <artifactId>camel-core</artifactId>
109 <version>${camel-spring-boot.version}</version>
112 <groupId>org.apache.camel</groupId>
113 <artifactId>camel-servlet-starter</artifactId>
116 <groupId>org.apache.camel</groupId>
117 <artifactId>camel-cxf</artifactId>
118 <version>${camel-spring-boot.version}</version>
120 <!-- Spring dependencies -->
122 <groupId>org.springframework.boot</groupId>
123 <artifactId>spring-boot-starter-web</artifactId>
126 <groupId>org.springframework.boot</groupId>
127 <artifactId>spring-boot-starter-tomcat</artifactId>
132 <groupId>org.springframework.boot</groupId>
133 <artifactId>spring-boot-starter-jetty</artifactId>
136 <groupId>org.springframework.boot</groupId>
137 <artifactId>spring-boot-starter</artifactId>
140 <groupId>org.springframework.boot</groupId>
141 <artifactId>spring-boot-starter-actuator</artifactId>
144 <groupId>javax.ws.rs</groupId>
145 <artifactId>javax.ws.rs-api</artifactId>
146 <version>2.1</version>
149 <groupId>org.powermock</groupId>
150 <artifactId>powermock-module-junit4</artifactId>
151 <version>1.6.2</version>
156 <groupId>org.assertj</groupId>
157 <artifactId>assertj-core</artifactId>
158 <version>3.10.0</version>
162 <groupId>org.powermock</groupId>
163 <artifactId>powermock-api-mockito</artifactId>
164 <version>1.6.2</version>
169 <groupId>org.powermock</groupId>
170 <artifactId>powermock-module-javaagent</artifactId>
171 <version>1.6.2</version>
176 <groupId>org.powermock</groupId>
177 <artifactId>powermock-module-junit4-rule-agent</artifactId>
178 <version>1.6.2</version>
182 <groupId>org.dom4j</groupId>
183 <artifactId>dom4j</artifactId>
184 <scope>provided</scope>
185 <version>2.1.1</version>
189 <groupId>com.att.aft</groupId>
190 <artifactId>dme2</artifactId>
191 <version>3.1.200-oss</version>
192 <scope>provided</scope>
196 <groupId>org.onap.aai.router-core</groupId>
197 <artifactId>router-core</artifactId>
198 <version>1.5.0</version>
202 <groupId>org.json</groupId>
203 <artifactId>json</artifactId>
207 <groupId>com.google.code.gson</groupId>
208 <artifactId>gson</artifactId>
209 <version>2.6.2</version>
213 <groupId>org.eclipse.persistence</groupId>
214 <artifactId>eclipselink</artifactId>
215 <version>2.6.2</version>
219 <groupId>org.onap.aai.logging-service</groupId>
220 <artifactId>common-logging</artifactId>
221 <version>1.5.0</version>
225 <groupId>org.onap.aai.logging-service</groupId>
226 <artifactId>logging-api</artifactId>
227 <version>1.5.0</version>
231 <groupId>org.onap.aai</groupId>
232 <artifactId>rest-client</artifactId>
233 <version>1.2.1</version>
237 <groupId>com.google.guava</groupId>
238 <artifactId>guava</artifactId>
239 <version>${version.com.google.guava}</version>
250 <groupId>org.codehaus.mojo</groupId>
251 <artifactId>build-helper-maven-plugin</artifactId>
252 <version>3.0.0</version>
255 <phase>pre-clean</phase>
256 <id>parse-version</id>
258 <goal>parse-version</goal>
264 <groupId>org.codehaus.groovy.maven</groupId>
265 <artifactId>gmaven-plugin</artifactId>
266 <version>1.0</version>
269 <phase>pre-clean</phase>
275 def userAaiBaseImage = session.userProperties['aai.base.image']
276 def userAaiCommonVersion = session.userProperties['aai.base.image.version']
277 if (userAaiCommonVersion != null) {
278 project.properties['aai.base.image.version'] = userAaiCommonVersion
280 if (userAaiBaseImage != null) {
281 project.properties['aai.base.image'] = userAaiBaseImage
283 log.info 'Base image flavour: ' + project.properties['aai.base.image']
284 log.info 'Base image version: ' + project.properties['aai.base.image.version']
291 <groupId>io.fabric8</groupId>
292 <artifactId>docker-maven-plugin</artifactId>
293 <version>${docker.fabric.version}</version>
295 <verbose>true</verbose>
296 <apiVersion>1.23</apiVersion>
299 <name>${docker.push.registry}/${aai.docker.namespace}/${project.artifactId}:%l
305 <tag>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest</tag>
306 <tag>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-${maven.build.timestamp}</tag>
308 <cleanup>try</cleanup>
309 <dockerFileDir>${project.basedir}/src/main/docker</dockerFileDir>
314 <directory>${aai.build.directory}</directory>
315 <outputDirectory>/${project.artifactId}</outputDirectory>
326 <id>clean-images</id>
327 <phase>pre-clean</phase>
332 <removeAll>true</removeAll>
336 <id>generate-images</id>
337 <phase>package</phase>
344 <phase>deploy</phase>
357 <finalName>${project.artifactId}</finalName>
359 <!-- jacoco-maven-plugin provides the basic report creation during unit testing, such as code-coverage, sonar, etc. -->
361 <groupId>org.jacoco</groupId>
362 <artifactId>jacoco-maven-plugin</artifactId>
364 <!-- Prepares the property pointing to the JaCoCo runtime agent which
365 is passed as VM argument when Maven the Surefire plugin is executed. -->
367 <id>pre-unit-test</id>
369 <goal>prepare-agent</goal>
372 <!-- Sets the path to the file which contains the execution data. -->
373 <destFile>${sonar.jacoco.reportPath}</destFile>
374 <propertyName>surefireArgLine</propertyName>
377 <!-- Ensures that the code coverage report for unit tests is created
378 after unit tests have been run. -->
380 <id>post-unit-test</id>
386 <!-- Sets the path to the file which contains the execution data. -->
387 <dataFile>${sonar.jacoco.reportPath}</dataFile>
388 <!-- Sets the output directory for the code coverage report. -->
389 <outputDirectory>${jacoco.path}</outputDirectory>
392 <!-- Prepares the property pointing to the JaCoCo runtime agent which
393 is passed as VM argument when Maven the Failsafe plugin is executed. -->
395 <id>pre-integration-test</id>
396 <phase>pre-integration-test</phase>
398 <goal>prepare-agent</goal>
401 <!-- Sets the path to the file which contains the execution data. -->
402 <destFile>${sonar.jacoco.itReportPath}</destFile>
403 <!-- Sets the name of the property containing the settings for JaCoCo
405 <propertyName>failsafeArgLine</propertyName>
408 <!-- Ensures that the code coverage report for integration tests after
409 integration tests have been run. -->
411 <id>post-integration-test</id>
412 <phase>post-integration-test</phase>
417 <!-- Sets the path to the file which contains the execution data. -->
418 <dataFile>${sonar.jacoco.itReportPath}/</dataFile>
419 <!-- Sets the output directory for the code coverage report. -->
420 <outputDirectory>${jacoco.itPath}</outputDirectory>
425 <!-- Checkstyle plugin - used to report on compliance with -->
426 <!-- the Google style guide. -->
428 <groupId>org.apache.maven.plugins</groupId>
429 <artifactId>maven-site-plugin</artifactId>
430 <version>3.3</version>
434 <groupId>org.apache.maven.plugins</groupId>
435 <artifactId>maven-checkstyle-plugin</artifactId>
436 <version>2.17</version>
440 <report>checkstyle</report>
450 <groupId>org.springframework.boot</groupId>
451 <artifactId>spring-boot-maven-plugin</artifactId>
455 <artifactId>maven-assembly-plugin</artifactId>
458 <descriptor>src/main/assembly/descriptor.xml</descriptor>
463 <id>make-assembly</id>
464 <phase>package</phase>
473 <artifactId>maven-surefire-plugin</artifactId>
474 <version>2.21.0</version>
476 <systemPropertyVariables>
477 <OXM_LOCATION>${aai.build.directory}</OXM_LOCATION>
478 <CONFIG_HOME>${project.basedir}/src/test/resources/config</CONFIG_HOME>
479 <SERVICE_BEANS>${project.basedir}/src/test/resources/spring-beans</SERVICE_BEANS>
480 <testShemaUnpackVersion>${shemaUnpackVersion}</testShemaUnpackVersion>
481 </systemPropertyVariables>
486 <groupId>org.apache.maven.plugins</groupId>
487 <artifactId>maven-dependency-plugin</artifactId>
491 <phase>initialize</phase>
498 <groupId>org.onap.aai.schema-service</groupId>
499 <artifactId>aai-schema</artifactId>
500 <version>${version.aai-schema}</version>
502 <includes>/${shemaUnpackVersion}/oxm/</includes>
503 <outputDirectory>${aai.build.directory}</outputDirectory>
510 <!-- license plugin -->
511 <!-- Uncomment this to add a license header to every source file
513 <groupId>com.mycila</groupId>
514 <artifactId>license-maven-plugin</artifactId>
515 <version>3.0</version>
517 <header>License.txt</header>
519 <include>src/main/java/**</include>
520 <include>src/test/java/**</include>
528 <phase>process-sources</phase>
533 <groupId>org.apache.maven.plugins</groupId>
534 <artifactId>maven-deploy-plugin</artifactId>
537 <groupId>org.codehaus.mojo</groupId>
538 <artifactId>sonar-maven-plugin</artifactId>
539 <version>3.2</version>
542 <groupId>org.jacoco</groupId>
543 <artifactId>jacoco-maven-plugin</artifactId>
544 <version>0.7.7.201606060606</version>
546 <dumpOnExit>true</dumpOnExit>
550 <id>jacoco-initialize-unit-tests</id>
552 <goal>prepare-agent</goal>
555 <destFile>${project.build.directory}/coverage-reports/jacoco.exec
560 <id>default-check</id>
565 <dataFile>${project.build.directory}/coverage-reports/jacoco.exec</dataFile>
567 <!-- implementation is needed only for Maven 2 -->
568 <rule implementation="org.jacoco.maven.RuleConfiguration">
569 <element>BUNDLE</element>
571 <limit implementation="org.jacoco.report.check.Limit">
572 <counter>LINE</counter>
573 <value>COVEREDRATIO</value>
574 <minimum>${jacoco.line.coverage.limit}</minimum>
588 <dependencyManagement>
591 <groupId>org.apache.camel</groupId>
592 <artifactId>camel-spring-boot-dependencies</artifactId>
593 <version>${camel-spring-boot.version}</version>
595 <scope>import</scope>
598 <groupId>org.apache.httpcomponents</groupId>
599 <artifactId>httpclient</artifactId>
600 <version>4.5.5</version>
603 <groupId>org.apache.httpcomponents</groupId>
604 <artifactId>httpcore</artifactId>
605 <version>4.4.1</version>
608 <groupId>org.json</groupId>
609 <artifactId>json</artifactId>
610 <version>20131018</version>
613 </dependencyManagement>
614 <distributionManagement>
616 <id>ecomp-releases</id>
617 <name>ECOMP Release Repository</name>
618 <url>${nexusproxy}/content/repositories/releases/</url>
621 <id>ecomp-snapshots</id>
622 <name>ECOMP Snapshot Repository</name>
623 <url>${nexusproxy}/content/repositories/snapshots/</url>
624 </snapshotRepository>
625 </distributionManagement>