<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>com.atlassian.pom</groupId>
        <artifactId>closedsource-pom</artifactId>
        <version>4.0.0</version>
    </parent>

    <scm>
        <connection>scm:git:ssh://git@bitbucket.org:atlassian/atlassian-connect-integration.git</connection>
        <developerConnection>scm:git:ssh://git@bitbucket.org/atlassian/atlassian-connect-integration.git</developerConnection>
        <url>https://bitbucket.org/atlassian/atlassian-connect-integration</url>
        <tag>HEAD</tag>
    </scm>

    <groupId>com.atlassian.fusion.plugins</groupId>
    <artifactId>atlassian-connect-integration-parent</artifactId>
    <version>0.0.14-D20151022T063250</version>
    <packaging>pom</packaging>

    <licenses>
        <license>
            <name>Atlassian End User License</name>
            <url>https://www.atlassian.com/end-user-agreement/</url>
            <comments>Atlassian 3.0 End User License Agreement</comments>
        </license>
    </licenses>

    <name>Atlassian Connect Integration</name>
    <description>Easy way to build P2 plugins that expose a Connect application</description>
    <inceptionYear>2015</inceptionYear>

    <issueManagement>
        <system>JIRA</system>
        <url>https://jdog.jira-dev.com/browse/FUSE</url>
    </issueManagement>

    <modules>
        <module>atlassian-connect-integration-api</module>
        <module>atlassian-connect-integration-plugin</module>
        <module>atlassian-connect-integration-testkit</module>
        <module>atlassian-connect-integration-test-resources</module>
    </modules>

    <properties>
        <platform.version>3.0.0</platform.version>
        <amps.version>6.0.6</amps.version>
        <maven.compiler.source>8</maven.compiler.source>
        <maven.compiler.target>8</maven.compiler.target>
        <source.encoding>UTF-8</source.encoding>

        <product>refapp</product>
        <product.version>${refapp.version}</product.version>

        <refapp.version>3.0.2</refapp.version>
        <jira.software.application.version>7.0.0-int-0019</jira.software.application.version>
        <jira.software.version>1.29-D20150806T075629</jira.software.version>
        <jira.version>7.0.0-QR20150917153646</jira.version>

        <apl.version>5.0.0</apl.version>
        <activeobjects.version>1.0.0</activeobjects.version>
        <plugin.testrunner.version>1.2.3</plugin.testrunner.version>
        <atlassian.spring.scanner.version>1.2.9</atlassian.spring.scanner.version>

        <slf4j.version>1.6.4</slf4j.version>

        <skipITs>true</skipITs>
        <skip.javadoc>false</skip.javadoc>

        <quickreload.version>1.27</quickreload.version>
        <analytics.version>4.2.2</analytics.version>

        <atlassian.annotations.version>0.16</atlassian.annotations.version>
        <xerces.version>2.9.1</xerces.version>
        <asm.version>3.3.1</asm.version>
        <jersey.server.version>1.8-atlassian-16</jersey.server.version>
        <saxon.version>8.7</saxon.version>
        <atlassian.rest.doclet.version>3.0.8</atlassian.rest.doclet.version>
    </properties>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-connect-integration-test-resources</artifactId>
                <version>${project.version}</version>
            </dependency>

            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-connect-integration-api</artifactId>
                <version>${project.version}</version>
            </dependency>

            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-connect-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>

            <dependency>
                <groupId>com.atlassian.platform</groupId>
                <artifactId>platform</artifactId>
                <version>${platform.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.platform</groupId>
                <artifactId>third-party</artifactId>
                <version>${platform.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.plugin</groupId>
                <artifactId>atlassian-spring-scanner-annotation</artifactId>
                <version>${atlassian.spring.scanner.version}</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.plugin</groupId>
                <artifactId>atlassian-spring-scanner-runtime</artifactId>
                <version>${atlassian.spring.scanner.version}</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.jwt</groupId>
                <artifactId>jwt-api</artifactId>
                <version>1.2.4</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.jwt</groupId>
                <artifactId>jwt-core</artifactId>
                <version>1.2.4</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.analytics</groupId>
                <artifactId>analytics-api</artifactId>
                <version>${analytics.version}</version>
            </dependency>
            <!-- Fugue three is not in platform yet, but will be peacefully co-exist with fugue 2. To be removed when platform updates -->
            <dependency>
                <groupId>io.atlassian.fugue</groupId>
                <artifactId>fugue</artifactId>
                <version>3.0.0</version>
            </dependency>

            <dependency>
                <groupId>javax.servlet</groupId>
                <artifactId>servlet-api</artifactId>
                <version>2.4</version>
            </dependency>
            <dependency>
                <groupId>javax.ws.rs</groupId>
                <artifactId>jsr311-api</artifactId>
                <version>1.1.1</version>
            </dependency>
            <dependency>
                <groupId>com.google.code.gson</groupId>
                <artifactId>gson</artifactId>
                <version>2.2.2-atlassian-1</version>
            </dependency>
            <dependency>
                <groupId>org.apache.commons</groupId>
                <artifactId>commons-lang3</artifactId>
                <version>3.1</version>
            </dependency>

            <dependency>
                <groupId>javax.inject</groupId>
                <artifactId>javax.inject</artifactId>
                <version>1</version>
            </dependency>
            <dependency>
                <groupId>org.hamcrest</groupId>
                <artifactId>java-hamcrest</artifactId>
                <version>2.0.0.0</version>
            </dependency>
            <dependency>
                <groupId>org.hamcrest</groupId>
                <artifactId>hamcrest-junit</artifactId>
                <version>2.0.0.0</version>
            </dependency>
            <dependency>
                <groupId>org.mockito</groupId>
                <artifactId>mockito-core</artifactId>
                <version>1.10.19</version>
            </dependency>
            <dependency>
                <groupId>commons-io</groupId>
                <artifactId>commons-io</artifactId>
                <version>2.4</version>
            </dependency>

            <!-- required for http client in tests, platform sets this to provided -->
            <dependency>
                <groupId>commons-logging</groupId>
                <artifactId>commons-logging</artifactId>
                <version>1.2</version>
            </dependency>

            <!-- required by manifesto/freezer -->
            <dependency>
                <groupId>com.atlassian</groupId>
                <artifactId>atlassian-test-categories</artifactId>
                <version>0.5</version>
            </dependency>

            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-connect-integration-testkit</artifactId>
                <version>${project.version}</version>
            </dependency>

            <!-- required for REST doc generation -->
            <dependency>
                <groupId>com.atlassian.plugins.rest</groupId>
                <artifactId>atlassian-rest-doclet</artifactId>
                <version>${atlassian.rest.doclet.version}</version>
            </dependency>
            <dependency>
                <groupId>xerces</groupId>
                <artifactId>xercesImpl</artifactId>
                <version>${xerces.version}</version>
            </dependency>
            <dependency>
                <groupId>com.sun.jersey</groupId>
                <artifactId>jersey-server</artifactId>
                <version>${jersey.server.version}</version>
            </dependency>
            <dependency>
                <groupId>asm</groupId>
                <artifactId>asm</artifactId>
                <version>${asm.version}</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.annotations</groupId>
                <artifactId>atlassian-annotations</artifactId>
                <version>${atlassian.annotations.version}</version>
            </dependency>

        </dependencies>
    </dependencyManagement>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <version>2.12.4</version>
                </plugin>
                <plugin>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.12.4</version>
                    <configuration>
                        <excludes>
                            <exclude>**/*$*</exclude>
                        </excludes>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>maven-amps-dispatcher-plugin</artifactId>
                    <version>${amps.version}</version>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>maven-amps-plugin</artifactId>
                    <version>${amps.version}</version>
                </plugin>
                <plugin>
                    <!-- use local checkout with Git -->
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <configuration>
                        <localCheckout>true</localCheckout>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <configuration>
                        <skip>${skip.javadoc}</skip>
                        <encoding>${source.encoding}</encoding>
                        <tags>
                            <tag>
                                <name>response.representation.200.doc</name>
                                <placement>X</placement>
                            </tag>
                            <tag>
                                <name>response.representation.204.doc</name>
                                <placement>X</placement>
                            </tag>
                            <tag>
                                <name>response.representation.400.doc</name>
                                <placement>X</placement>
                            </tag>
                            <tag>
                                <name>response.representation.401.doc</name>
                                <placement>X</placement>
                            </tag>
                            <tag>
                                <name>response.representation.404.doc</name>
                                <placement>X</placement>
                            </tag>
                            <tag>
                                <name>request.representation.doc</name>
                                <placement>X</placement>
                            </tag>
                            <tag>
                                <name>request.representation.mediaType</name>
                                <placement>X</placement>
                            </tag>
                        </tags>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-resources-plugin</artifactId>
                    <configuration>
                        <encoding>${source.encoding}</encoding>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-enforcer-plugin</artifactId>
                    <configuration>
                        <rules>
                            <requireJavaVersion>
                                <!-- Because the current JIRA 6.5 OD release creates Java 8 class files  -->
                                <version>1.8</version>
                            </requireJavaVersion>
                            <requireMavenVersion>
                                <version>[${maven.min.version},)</version>
                            </requireMavenVersion>
                        </rules>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>com.sun.jersey.contribs</groupId>
                    <artifactId>maven-wadl-plugin</artifactId>
                    <version>1.8</version>
                </plugin>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>xml-maven-plugin</artifactId>
                    <version>1.0</version>
                </plugin>
                <plugin>
                    <artifactId>maven-antrun-plugin</artifactId>
                    <version>1.7</version>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>

    <repositories>
        <repository>
            <id>atlassian-3rdparty</id>
            <url>https://maven.atlassian.com/service/local/repositories/atlassian-3rdparty/content/</url>
            <snapshots>
                <enabled>false</enabled>
                <updatePolicy>never</updatePolicy>
            </snapshots>
            <releases>
                <checksumPolicy>fail</checksumPolicy>
            </releases>
        </repository>
    </repositories>

    <profiles>
        <profile>
            <id>sonar</id>
            <properties>
                <sonar.jdbc.url>jdbc:postgresql://sonarqube-db.internal.atlassian.com/sonar</sonar.jdbc.url>
                <sonar.jdbc.driver>org.postgresql.Driver</sonar.jdbc.driver>
                <sonar.jdbc.username>sonar</sonar.jdbc.username>
                <sonar.jdbc.password>sonar</sonar.jdbc.password>
                <sonar.host.url>http://ec402.prod.inf.atlassian.com:9000/</sonar.host.url>
            </properties>
            <!-- Exclude test modules so they don't affect the overall metrics for DevStatus -->
            <modules>
                <module>atlassian-connect-integration-api</module>
                <module>atlassian-connect-integration-plugin</module>
            </modules>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.codehaus.mojo</groupId>
                        <artifactId>sonar-maven-plugin</artifactId>
                        <version>2.6</version>
                        <dependencies>
                            <dependency>
                                <groupId>org.postgresql</groupId>
                                <artifactId>postgresql</artifactId>
                                <version>9.4-1201-jdbc41</version>
                            </dependency>
                        </dependencies>
                    </plugin>
                    <plugin>
                        <groupId>org.jacoco</groupId>
                        <artifactId>jacoco-maven-plugin</artifactId>
                        <version>0.7.5.201505241946</version>
                        <executions>
                            <execution>
                                <id>prepare-agent</id>
                                <goals>
                                    <goal>prepare-agent</goal>
                                </goals>
                            </execution>
                            <execution>
                                <id>report</id>
                                <phase>prepare-package</phase>
                                <goals>
                                    <goal>report</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
