revert topic exist topic check while publishing
[dmaap/messagerouter/messageservice.git] / pom.xml
diff --git a/pom.xml b/pom.xml
index 0dbf611..19c479c 100644 (file)
--- a/pom.xml
+++ b/pom.xml
        <parent>
                <groupId>org.onap.oparent</groupId>
                <artifactId>oparent</artifactId>
-               <version>1.2.1</version>
+               <version>2.0.0</version>
        </parent>
 
        <groupId>org.onap.dmaap.messagerouter.messageservice</groupId>
        <artifactId>dmaapMR1</artifactId>
-       <version>1.1.11-SNAPSHOT</version>
+       <version>1.1.16-SNAPSHOT</version>
        <name>dmaap-messagerouter-messageservice</name>
        <description>Message Router - Restful interface built for kafka</description>
        <licenses>
@@ -47,6 +47,7 @@
 
        <build>
                <plugins>
+
                        <plugin>
                                <groupId>org.apache.maven.plugins</groupId>
                                <artifactId>maven-site-plugin</artifactId>
                                <artifactId>maven-jar-plugin</artifactId>
                                <version>3.0.2</version>
                        </plugin>
-
-                       <!-- <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-javadoc-plugin</artifactId> 
-                               <version>2.10.4</version> <configuration> <additionalparam>-Xdoclint:none</additionalparam> 
-                               </configuration> <executions> <execution> <id>attach-javadocs</id> <goals> 
-                               <goal>jar</goal> </goals> </execution> </executions> </plugin> -->
                        <plugin>
                                <groupId>org.apache.maven.plugins</groupId>
                                <artifactId>maven-source-plugin</artifactId>
                                        </dependency>
                                </dependencies>
                        </plugin>
+                
 
-                       <plugin>
-                               <groupId>com.spotify</groupId>
-                               <artifactId>docker-maven-plugin</artifactId>
-                               <version>1.0.0</version>
-                               <configuration>
-                                       <imageName>onap/dmaap/dmaap-mr</imageName>
-                                       <dockerDirectory>${dockerLocation}</dockerDirectory>
-                                       <serverId>docker-hub</serverId>
-                                       <imageTags>
-                                               <imageTag>${dmaapImg}</imageTag>
-                                               <imageTag>latest</imageTag>
-                                       </imageTags>
-                                       <forceTags>true</forceTags>
-                                       <resources>
-                                               <resource>
-                                                       <targetPath>/</targetPath>
-                                                       <directory>${dockerLocation}</directory>
-                                                       <include>${project.build.finalName}.jar</include>
-                                               </resource>
-                                               <resource>
-                                                       <targetPath>/</targetPath>
-                                                       <directory>${project.build.directory}</directory>
-                                                       <include>**/**</include>
-                                               </resource>
-                                       </resources>
-                               </configuration>
-                               <executions>
-                                       <execution>
-                                               <id>build-image</id>
-                                               <phase>install</phase>
-                                               <goals>
-                                                       <goal>build</goal>
-                                               </goals>
-                                               <configuration>
-                                                       <skipDockerBuild>${skip.docker.build}</skipDockerBuild>
-                                               </configuration>
-                                       </execution>
-
-                                       <execution>
-                                               <id>tag-image-project-version</id>
-                                               <phase>install</phase>
-                                               <goals>
-                                                       <goal>tag</goal>
-                                               </goals>
-                                               <configuration>
-                                                       <image>onap/dmaap/dmaap-mr</image>
-                                                       <newName>${docker.push.registry}/onap/dmaap/dmaap-mr:${project.version}</newName>
-                                                       <skipDockerTag>${skip.docker.push}</skipDockerTag>
-                                               </configuration>
-                                       </execution>
-
-                                       <execution>
-                                               <id>tag-image-latest</id>
-                                               <phase>install</phase>
-                                               <goals>
-                                                       <goal>tag</goal>
-                                               </goals>
-                                               <configuration>
-                                                       <image>onap/dmaap/dmaap-mr</image>
-                                                       <newName>${docker.push.registry}/onap/dmaap/dmaap-mr:latest</newName>
-                                                       <skipDockerTag>${skip.docker.push}</skipDockerTag>
-                                               </configuration>
-                                       </execution>
-
-                                       <execution>
-                                               <id>push-image-latest</id>
-                                               <phase>deploy</phase>
-                                               <goals>
-                                                       <goal>push</goal>
-                                               </goals>
-                                               <configuration>
-                                                       <imageName>${docker.push.registry}/onap/dmaap/dmaap-mr:${project.version}</imageName>
-                                                       <skipDockerPush>${skip.docker.push}</skipDockerPush>
-                                               </configuration>
-                                       </execution>
-
-                                       <execution>
-                                               <id>push-image</id>
-                                               <phase>deploy</phase>
-                                               <goals>
-                                                       <goal>push</goal>
-                                               </goals>
-                                               <configuration>
-                                                       <imageName>${docker.push.registry}/onap/dmaap/dmaap-mr:latest</imageName>
-                                                       <skipDockerPush>${skip.docker.push}</skipDockerPush>
-                                               </configuration>
-                                       </execution>
-                               </executions>
-                       </plugin>
                        <plugin>
                                <groupId>com.blackducksoftware.integration</groupId>
                                <artifactId>hub-maven-plugin</artifactId>
                <!-- <javax-mail-version>1.5.0</javax-mail-version> -->
                <module.ajsc.namespace.name>dmaap</module.ajsc.namespace.name>
                <module.ajsc.namespace.version>v1</module.ajsc.namespace.version>
-               <ajscRuntimeVersion>3.0.10-oss</ajscRuntimeVersion>
+               <ajscRuntimeVersion>3.0.11-oss</ajscRuntimeVersion>
 
                <!-- This will be the Absolute Root of the Project and should contain NO 
                        Versioning -->
                <testRouteOffer>workstation</testRouteOffer>
                <testEnv>DEV</testEnv>
                <!-- <dmaapImg>${project.version}</dmaapImg> -->
-               <dmaapImg>1.1.10</dmaapImg>
-               <camel.version>2.21.1</camel.version>
+               <timestamp>${maven.build.timestamp}</timestamp>
+        <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
+               <camel.version>2.21.5</camel.version>
                <sitePath>/content/sites/site/org/onap/dmaap/messagerouter/messageservice/${project.artifactId}/${project.version}</sitePath>
                <skip.docker.build>true</skip.docker.build>
+               <skip.docker.tag>true</skip.docker.tag>
                <skip.docker.push>true</skip.docker.push>
                <nexusproxy>https://nexus.onap.org</nexusproxy>
                <docker.push.registry>nexus3.onap.org:10003</docker.push.registry>
                                </exclusion>
                        </exclusions>
                </dependency>
+               <dependency>
+                       <groupId>commons-fileupload</groupId>
+                       <artifactId>commons-fileupload</artifactId>
+                       <version>1.4</version>
+               </dependency>
                <dependency>
                        <groupId>org.springframework</groupId>
                        <artifactId>spring-webmvc</artifactId>
                <dependency>
                        <groupId>org.onap.dmaap.messagerouter.msgrtr</groupId>
                        <artifactId>msgrtr</artifactId>
-                       <version>1.1.15</version>
+                       <version>1.1.19</version>
                        <exclusions>
                                <exclusion>
                                        <groupId>org.slf4j</groupId>
                                        <groupId>commons-beanutils</groupId>
                                        <artifactId>commons-beanutils</artifactId>
                                </exclusion>
+                               <exclusion>
+                                       <groupId>javax.mail</groupId>
+                                       <artifactId>mail</artifactId>
+                               </exclusion>
                        </exclusions>
                </dependency>
                <dependency>
                <dependency>
                        <groupId>com.att.ajsc</groupId>
                        <artifactId>ajsc-archetype-parent</artifactId>
-                       <version>3.0.10-oss</version>
+                       <version>3.0.11-oss</version>
                        <type>pom</type>
                </dependency>
 
        <dependency>
                <groupId>org.onap.aaf.authz</groupId>
                <artifactId>aaf-cadi-aaf</artifactId>
-               <version>2.1.5</version>
+               <version>2.1.13</version>
        </dependency>
        <dependency>
                <groupId>backport-util-concurrent</groupId>
                <dependency>
                        <groupId>com.att.ajsc</groupId>
                        <artifactId>ajsc-runner</artifactId>
-                       <version>3.0.10-oss</version>
+                       <version>3.0.11-oss</version>
                        <scope>runtime</scope>
                </dependency>
                <dependency>
                        <groupId>com.att.ajsc</groupId>
                        <artifactId>ajsc-core</artifactId>
-                       <version>3.0.10-oss</version>
+                       <version>3.0.11-oss</version>
                        <scope>provided</scope>
                </dependency>
+               <dependency>
+                       <groupId>org.springframework</groupId>
+                       <artifactId>spring-test</artifactId>
+                       <version>3.2.12.RELEASE</version>
+                       <scope>test</scope>
+               </dependency>
        </dependencies>
        <!-- <build> <resources> <resource> <directory>${basedir}/ajsc-shared-config/etc</directory> 
                </resource> </resources> </build> -->
                <profile>
                        <id>docker</id>
                        <properties>
-
                                <skip.docker.build>false</skip.docker.build>
                                <skip.docker.tag>false</skip.docker.tag>
                                <skip.docker.push>false</skip.docker.push>
                        </properties>
+                       <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.codehaus.groovy.maven</groupId>
+                        <artifactId>gmaven-plugin</artifactId>
+                        <executions>
+                            <execution>
+                                <phase>validate</phase>
+                                <goals>
+                                    <goal>execute</goal>
+                                </goals>
+                                <configuration>
+                                    <properties>
+                                        <ver>${project.version}</ver>
+                                        <timestamp>${maven.build.timestamp}</timestamp>
+                                    </properties>
+                                    <source>
+                                        println project.properties['ver'];
+                                        if ( project.properties['ver'].endsWith("-SNAPSHOT") ) {
+                                        project.properties['dockertag1']=project.properties['ver'] + "-latest";
+                                        project.properties['dockertag2']=project.properties['ver'] + "-" + project.properties['timestamp'];
+                                        } else {
+                                        project.properties['dockertag1']=project.properties['ver'] + "-STAGING-latest";
+                                        project.properties['dockertag2']=project.properties['ver'] + "-STAGING-" + project.properties['timestamp'];
+                                        }
+                                        println 'docker tag 1: ' + project.properties['dockertag1'];
+                                        println 'docker tag 2: ' + project.properties['dockertag2'];
+                                    </source>
+                                </configuration>
+                            </execution>
+                        </executions>
+                    </plugin>
+                   <plugin>
+                        <groupId>io.fabric8</groupId>
+                        <artifactId>docker-maven-plugin</artifactId>
+                        <version>0.28.0</version>  
+                        <configuration>
+                            <verbose>${docker.verbose}</verbose>
+                            <apiVersion>${docker.apiVersion}</apiVersion>
+                            <pullRegistry>${docker.pull.registry}</pullRegistry>
+                            <pushRegistry>${docker.push.registry}</pushRegistry>
+                            <images>
+                                <image>                            
+                                    <name>onap/dmaap/dmaap-mr</name>
+                                    <build>
+                                        <cleanup>try</cleanup>
+                                        <dockerFileDir>${dockerLocation}</dockerFileDir>
+                                        <dockerFile>Dockerfile</dockerFile>
+                                        <tags>
+                                            <tag>${dockertag1}</tag>
+                                            <tag>${dockertag2}</tag>
+                                        </tags>
+                                    </build>
+                                </image>
+                            </images>
+                        </configuration>
+                         <executions>
+                             <execution>
+                                 <id>generate-images</id>
+                                 <phase>install</phase>
+                                 <goals>
+                                     <goal>build</goal>
+                                 </goals>
+                             </execution>
+                             <execution>
+                                 <id>push-images</id>
+                                 <phase>deploy</phase>
+                                 <goals>
+                                     <goal>push</goal>
+                                 </goals>
+                             </execution>
+                         </executions>
+                    </plugin>
+                </plugins>
+            </build>
                </profile>
 
                <profile>