1 <!-- ============LICENSE_START=======================================================
2 org.onap.dmaap ================================================================================
3 Copyright © 2017 AT&T Intellectual Property. All rights reserved. ================================================================================
4 Licensed under the Apache License, Version 2.0 (the "License"); you may not
5 use this file except in compliance with the License. You may obtain a copy
6 of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required
7 by applicable law or agreed to in writing, software distributed under the
8 License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS
9 OF ANY KIND, either express or implied. See the License for the specific
10 language governing permissions and limitations under the License. ============LICENSE_END=========================================================
11 ECOMP is a trademark and service mark of AT&T Intellectual Property. -->
12 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
13 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
14 <modelVersion>4.0.0</modelVersion>
17 <groupId>org.onap.oparent</groupId>
18 <artifactId>oparent</artifactId>
19 <version>2.1.0</version>
22 <groupId>org.onap.dmaap.kafka</groupId>
23 <artifactId>kafka11aaf</artifactId>
24 <version>1.0.4-SNAPSHOT</version>
25 <name>dmaap-kafka</name>
28 <name>Apache License Version 2.0</name>
34 <name>Sunil Unnava</name>
36 <organization>ATT</organization>
37 <organizationUrl>www.att.com</organizationUrl>
42 <!-- Copy files to docker-stage to be included in image -->
45 <targetPath>${basedir}/target/docker-stage</targetPath>
46 <directory>${basedir}/src/main/docker</directory>
49 <directory>${basedir}/src/main/resources</directory>
56 <groupId>org.jacoco</groupId>
57 <artifactId>jacoco-maven-plugin</artifactId>
60 <id>prepare-agent</id>
62 <goal>prepare-agent</goal>
71 <dataFile>${project.build.directory}/code-coverage/jacoco.exec</dataFile>
72 <outputDirectory>${project.reporting.outputDirectory}/jacoco-ut</outputDirectory>
78 <groupId>org.apache.maven.plugins</groupId>
79 <artifactId>maven-surefire-plugin</artifactId>
80 <version>2.12.4</version>
83 <!-- exclude until junits updated <exclude>**/DME2*.java</exclude> -->
85 <!-- <skipTests>true</skipTests> -->
89 <groupId>org.apache.maven.plugins</groupId>
90 <artifactId>maven-site-plugin</artifactId>
91 <version>3.6</version>
94 <groupId>org.apache.maven.wagon</groupId>
95 <artifactId>wagon-webdav-jackrabbit</artifactId>
96 <version>2.10</version>
101 <!-- <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId>
102 <version>3.0.2</version> </plugin> -->
105 <groupId>org.apache.maven.plugins</groupId>
106 <artifactId>maven-source-plugin</artifactId>
107 <version>3.0.0</version>
110 <id>attach-sources</id>
112 <goal>jar-no-fork</goal>
118 <groupId>org.apache.maven.plugins</groupId>
119 <artifactId>maven-release-plugin</artifactId>
120 <version>2.5.3</version>
122 <autoVersionSubmodules>true</autoVersionSubmodules>
123 <checkModificationExcludes>
124 </checkModificationExcludes>
128 <groupId>org.apache.maven.scm</groupId>
129 <artifactId>maven-scm-provider-gitexe</artifactId>
130 <version>1.9.4</version>
136 <artifactId>maven-deploy-plugin</artifactId>
137 <version>2.8</version>
140 <id>default-deploy</id>
152 <artifactId>maven-dependency-plugin</artifactId>
156 <phase>package</phase>
161 <outputDirectory>target</outputDirectory>
162 <encoding>UTF-8</encoding>
165 <groupId>org.onap.dmaap.messagerouter.mirroragent</groupId>
166 <artifactId>dmaapMMAgent</artifactId>
167 <version>1.1.2</version>
168 <destFileName>dmaapMMAgent.jar</destFileName>
176 <artifactId>maven-resources-plugin</artifactId>
177 <version>2.7</version>
181 <phase>install</phase>
183 <goal>copy-resources</goal>
186 <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
189 <directory>${basedir}/target</directory>
191 <include>dmaapMMAgent.jar</include>
192 <include>kafka11aaf-jar-with-dependencies.jar</include>
201 <groupId>org.apache.maven.plugins</groupId>
202 <artifactId>maven-assembly-plugin</artifactId>
203 <version>2.4.1</version>
205 <!-- get all project dependencies -->
207 <descriptorRef>jar-with-dependencies</descriptorRef>
209 <!-- MainClass in mainfest make a executable jar -->
210 <finalName>kafka11aaf</finalName>
214 <id>make-assembly</id>
215 <!-- bind to the packaging phase -->
216 <phase>package</phase>
228 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
229 <timestamp>${maven.build.timestamp}</timestamp>
230 <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
231 <sitePath>/content/sites/site/org/onap/dmaap/kafka0111/${project.artifactId}/${project.version}</sitePath>
232 <skip.docker.build>true</skip.docker.build>
233 <skip.docker.push>true</skip.docker.push>
234 <nexusproxy>https://nexus.onap.org</nexusproxy>
235 <docker.push.registry>nexus3.onap.org:10003</docker.push.registry>
236 <onap.nexus.url>https://nexus.onap.org</onap.nexus.url>
237 <sonar.language>java</sonar.language>
238 <sonar.skip>false</sonar.skip>
239 <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
240 <sonar.coverage.jacoco.xmlReportPaths>${project.reporting.outputDirectory}/jacoco-ut/jacoco.xml</sonar.coverage.jacoco.xmlReportPaths>
241 <sonar.projectVersion>${project.version}</sonar.projectVersion>
244 <!-- Distribution management -->
245 <distributionManagement>
248 <url>dav:${nexusproxy}${sitePath}</url>
250 </distributionManagement>
254 <groupId>org.onap.aaf.authz</groupId>
255 <artifactId>aaf-cadi-aaf</artifactId>
256 <version>2.1.2</version>
259 <groupId>org.slf4j</groupId>
260 <artifactId>slf4j-api</artifactId>
261 <version>1.7.2</version>
264 <groupId>org.slf4j</groupId>
265 <artifactId>slf4j-simple</artifactId>
266 <version>1.7.2</version>
267 <scope>runtime</scope>
270 <groupId>org.apache.kafka</groupId>
271 <artifactId>kafka_2.11</artifactId>
272 <version>2.3.0</version>
273 <scope>provided</scope>
277 <groupId>org.powermock</groupId>
278 <artifactId>powermock-api-mockito</artifactId>
279 <version>1.6.4</version>
284 <groupId>org.powermock</groupId>
285 <artifactId>powermock-module-junit4</artifactId>
286 <version>1.6.4</version>
291 <groupId>org.powermock</groupId>
292 <artifactId>powermock-module-junit4-rule</artifactId>
293 <version>1.6.4</version>
297 <groupId>org.mockito</groupId>
298 <artifactId>mockito-core</artifactId>
299 <version>1.10.19</version>
308 <skip.docker.build>false</skip.docker.build>
309 <skip.docker.tag>false</skip.docker.tag>
310 <skip.docker.push>false</skip.docker.push>
315 <groupId>org.codehaus.groovy.maven</groupId>
316 <artifactId>gmaven-plugin</artifactId>
319 <phase>validate</phase>
325 <ver>${project.version}</ver>
326 <timestamp>${maven.build.timestamp}</timestamp>
329 println project.properties['ver'];
330 if ( project.properties['ver'].endsWith("-SNAPSHOT") ) {
331 project.properties['dockertag1']=project.properties['ver'] +
333 project.properties['dockertag2']=project.properties['ver'] +
334 "-" + project.properties['timestamp'];
336 project.properties['dockertag1']=project.properties['ver'] +
338 project.properties['dockertag2']=project.properties['ver'] +
339 "-STAGING-" + project.properties['timestamp'];
341 println 'docker tag 1: ' + project.properties['dockertag1'];
342 println 'docker tag 2: ' + project.properties['dockertag2'];
348 <!-- build docker image -->
350 <groupId>io.fabric8</groupId>
351 <artifactId>docker-maven-plugin</artifactId>
352 <version>0.28.0</version>
354 <verbose>${docker.verbose}</verbose>
355 <apiVersion>${docker.apiVersion}</apiVersion>
356 <pullRegistry>${docker.pull.registry}</pullRegistry>
357 <pushRegistry>${docker.push.registry}</pushRegistry>
360 <name>onap/dmaap/kafka111</name>
362 <cleanup>try</cleanup>
363 <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
364 <dockerFile>Dockerfile</dockerFile>
366 <tag>${dockertag1}</tag>
367 <tag>${dockertag2}</tag>
375 <id>generate-images</id>
376 <phase>install</phase>
383 <phase>deploy</phase>