<?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/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

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

    <groupId>com.atlassian.gadgets</groupId>
    <artifactId>atlassian-gadgets</artifactId>
    <version>9.0.33</version>
    <packaging>pom</packaging>

    <name>Atlassian Gadgets</name>
    <description>Plugins and infrastructure for displaying gadgets and creating dashboards in Atlassian products</description>
    <licenses>
        <license>
            <name>Atlassian Customer Agreement</name>
            <url>https://www.atlassian.com/customer-agreement/</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <modules>
        <module>api</module>
        <module>spi</module>
        <module>shared</module>
        <module>test-framework</module>
        <module>opensocial-plugin</module>
        <module>embedded-plugin</module>
        <module>dashboard-plugin</module>
        <module>directory-plugin</module>
        <module>publisher-plugin</module>
        <module>sample-gadgets-plugin</module>
        <module>refimpl-dashboard-plugin</module>
        <module>refimpl-dashboard-ui-plugin</module>
        <module>oauth-service-provider-plugin</module>
        <module>atlassian-gadgets-pageobjects</module>
        <module>gadget-tests</module>
        <module>jira-runner</module>
        <module>sonar-aggregator</module>
    </modules>

    <scm>
        <connection>scm:git:git@bitbucket.org:atlassian/dc-platform-closed-source.git</connection>
        <developerConnection>scm:git:git@bitbucket.org:atlassian/dc-platform-closed-source.git</developerConnection>
        <url>https://bitbucket.org/atlassian/dc-platform-closed-source</url>
        <tag>atlassian-gadgets-9.0.33</tag>
    </scm>
    <issueManagement>
        <system>Jira</system>
        <url>https://ecosystem.atlassian.net/browse/AG</url>
    </issueManagement>
    <ciManagement>
        <system>Bamboo</system>
        <url>https://ecosystem-bamboo.internal.atlassian.com/browse/GADGETS</url>
    </ciManagement>

    <properties>
        <maven.compiler.release>17</maven.compiler.release>
        <jira.version>10.0.0-QR-20240702110459</jira.version>
        <amps.version>9.7.0</amps.version>
        <atlassian.refapp.version>${platform.version}</atlassian.refapp.version>
        <platform.version>7.0.24-8a7a87843</platform.version>
        <!-- atlassian-oauth-bridge version is not managed by Platform -->
        <atlassian-oauth.version>6.0.3</atlassian-oauth.version>
        <shindig.version>3.0.9</shindig.version>
        <refapp.pageobjects.version>${atlassian.refapp.version}</refapp.pageobjects.version>
        <atlassian.selenium.version>3.3.5</atlassian.selenium.version>
        <atlassian.spring.scanner.version>2.1.7</atlassian.spring.scanner.version>
        <atlassian.qunit.plugin.version>2.0.5</atlassian.qunit.plugin.version>
        <atlassian.whitelist.version>6.0.2</atlassian.whitelist.version>
        <httpcache4j.version>5.1.1</httpcache4j.version>
        <hamcrest.version>1.4-atlassian-1</hamcrest.version>
        <javadoc.additional.params>-Xdoclint:none</javadoc.additional.params>
        <failOnMilestoneOrReleaseCandidateDeps>false</failOnMilestoneOrReleaseCandidateDeps>
        <jacoco.report.file>sonar-aggregator/target/site/jacoco-aggregate/jacoco.xml</jacoco.report.file>
        <sonar.coverage.exclusions>
            test-framework/**,
            atlassian-gadgets-pageobjects/**,
            gadget-tests/**,
            jira-runner/**,
            sample-gadgets-plugin/**
        </sonar.coverage.exclusions>
        <xstream.version>1.4.21</xstream.version>
        <jvm.opens>
            --add-opens=java.base/java.lang=ALL-UNNAMED
            --add-opens=java.base/java.io=ALL-UNNAMED
            --add-opens=java.base/java.net=ALL-UNNAMED
            --add-opens=java.base/java.util=ALL-UNNAMED
            --add-opens=java.base/java.util.regex=ALL-UNNAMED
            --add-opens=java.base/sun.net.spi=ALL-UNNAMED
        </jvm.opens>
        <frontend-maven-plugin.version>1.15.0</frontend-maven-plugin.version>
        <frontend-maven-plugin.node.version>v20.9.0</frontend-maven-plugin.node.version>
        <frontend-maven-plugin.yarn.version>v1.22.19</frontend-maven-plugin.yarn.version>
    </properties>

    <dependencyManagement>
        <dependencies>
            <!-- Platform deps -->
            <dependency>
                <groupId>com.atlassian.platform.dependencies</groupId>
                <artifactId>platform-deprecated-public-api</artifactId>
                <version>${platform.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.platform.dependencies</groupId>
                <artifactId>platform-internal-api</artifactId>
                <version>${platform.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.platform.dependencies</groupId>
                <artifactId>platform-public-api</artifactId>
                <version>${platform.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.platform.dependencies</groupId>
                <artifactId>platform-test-resources</artifactId>
                <version>${platform.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.oauth</groupId>
                <artifactId>atlassian-oauth-bridge</artifactId>
                <version>${atlassian-oauth.version}</version>
            </dependency>
            <!-- Modules -->
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-api</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-spi</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-test-framework</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-dashboard-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-directory-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-embedded-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-oauth-service-provider-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-opensocial-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-pageobjects</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-publisher-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-refimpl-dashboard-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-refimpl-dashboard-ui-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-sample-gadgets-plugin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>${project.groupId}</groupId>
                <artifactId>atlassian-gadgets-shared</artifactId>
                <version>${project.version}</version>
            </dependency>
            <!-- Transformless plugin deps -->
            <dependency>
                <groupId>com.atlassian.plugin</groupId>
                <artifactId>atlassian-spring-scanner-annotation</artifactId>
                <version>${atlassian.spring.scanner.version}</version>
                <scope>provided</scope>
            </dependency>
            <!-- Compile-time, bundled dependencies -->
            <dependency>
                <groupId>com.google.inject</groupId>
                <artifactId>guice</artifactId>
                <version>4.2.3</version>
            </dependency>
            <dependency>
                <groupId>jaxen</groupId>
                <artifactId>jaxen</artifactId>
                <version>1.2.0-atlassian-2</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.bundles</groupId>
                <artifactId>icu4j</artifactId>
                <version>3.8-1</version>
                <scope>provided</scope>
            </dependency>
            <dependency>
                <groupId>net.jcip</groupId>
                <artifactId>jcip-annotations</artifactId>
                <version>1.0</version>
            </dependency>
            <dependency>
                <groupId>xalan</groupId>
                <artifactId>xalan</artifactId>
                <version>2.7.2</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.shindig</groupId>
                <artifactId>shindig-common</artifactId>
                <version>${shindig.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>net.sf.ehcache</groupId>
                        <artifactId>ehcache</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.hamcrest</groupId>
                        <artifactId>hamcrest-all</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.json</groupId>
                        <artifactId>json</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>aopalliance</groupId>
                <artifactId>aopalliance</artifactId>
                <version>1.0</version>
                <scope>provided</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.shindig</groupId>
                <artifactId>shindig-social-api</artifactId>
                <version>${shindig.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>commons-betwixt</groupId>
                        <artifactId>commons-betwixt</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>commons-collections</groupId>
                        <artifactId>commons-collections</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>commons-httpclient</groupId>
                        <artifactId>commons-httpclient</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>net.sf.json-lib</groupId>
                        <artifactId>json-lib</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>net.sf.ezmorph</groupId>
                        <artifactId>ezmorph</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.apache.geronimo.specs</groupId>
                        <artifactId>geronimo-stax-api_1.0_spec</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.json</groupId>
                        <artifactId>json</artifactId>
                    </exclusion>
                    <exclusion>
                        <!-- provided by platform-public-api -->
                        <groupId>xml-apis</groupId>
                        <artifactId>xml-apis</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>xpp3</groupId>
                        <artifactId>xpp3</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>com.atlassian.shindig</groupId>
                <artifactId>shindig-gadgets</artifactId>
                <version>${shindig.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>caja</groupId>
                        <artifactId>caja</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>caja</groupId>
                        <artifactId>json_simple</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>commons-io</groupId>
                        <artifactId>commons-io</artifactId>
                    </exclusion>
                    <exclusion>
                        <artifactId>commons-logging</artifactId>
                        <groupId>commons-logging</groupId>
                    </exclusion>
                    <exclusion>
                        <groupId>com.ibm.icu</groupId>
                        <artifactId>icu4j</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>net.sourceforge.nekohtml</groupId>
                        <artifactId>nekohtml</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.json</groupId>
                        <artifactId>json</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>rome</groupId>
                        <artifactId>rome</artifactId>
                    </exclusion>
                    <exclusion>
                        <!-- provided by platform-public-api -->
                        <groupId>xerces</groupId>
                        <artifactId>xercesImpl</artifactId>
                    </exclusion>
                    <exclusion>
                        <!-- provided by platform-public-api -->
                        <groupId>xml-apis</groupId>
                        <artifactId>xml-apis</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>com.atlassian.plugins</groupId>
                <artifactId>atlassian-whitelist-api-plugin</artifactId>
                <version>${atlassian.whitelist.version}</version>
            </dependency>
            <dependency>
                <groupId>org.codehaus.httpcache4j</groupId>
                <artifactId>httpcache4j-api</artifactId>
                <version>${httpcache4j.version}</version>
            </dependency>
            <dependency>
                <groupId>org.codehaus.httpcache4j</groupId>
                <artifactId>httpcache4j-core</artifactId>
                <version>${httpcache4j.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>commons-codec</groupId>
                        <artifactId>commons-codec</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>javax.activation</groupId>
                        <artifactId>activation</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>com.google.collections</groupId>
                        <artifactId>google-collections</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>joda-time</groupId>
                        <artifactId>joda-time</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.codehaus.jackson</groupId>
                        <artifactId>jackson-mapper-asl</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>org.codehaus.httpcache4j</groupId>
                <artifactId>httpcache4j-storage-api</artifactId>
                <version>${httpcache4j.version}</version>
            </dependency>
            <dependency>
                <groupId>com.thoughtworks.xstream</groupId>
                <artifactId>xstream</artifactId>
                <version>${xstream.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>xmlpull</groupId>
                        <artifactId>xmlpull</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <!-- Runtime-only dependencies -->
            <dependency>
                <groupId>com.atlassian.shindig</groupId>
                <artifactId>shindig-features</artifactId>
                <version>${shindig.version}</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.jira</groupId>
                <artifactId>jira-api</artifactId>
                <version>${jira.version}</version>
                <scope>provided</scope>
                <exclusions>
                    <exclusion>
                        <groupId>*</groupId>
                        <artifactId>*</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>com.atlassian.refapp</groupId>
                <artifactId>atlassian-refapp-pageobjects</artifactId>
                <version>${refapp.pageobjects.version}</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.selenium</groupId>
                <artifactId>atlassian-pageobjects-api</artifactId>
                <version>${atlassian.selenium.version}</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.selenium</groupId>
                <artifactId>atlassian-pageobjects-elements</artifactId>
                <version>${atlassian.selenium.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>commons-logging</groupId>
                        <artifactId>commons-logging</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>commons-io</groupId>
                        <artifactId>commons-io</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>com.atlassian.qunit</groupId>
                <artifactId>atlassian-qunit-plugin</artifactId>
                <version>${atlassian.qunit.plugin.version}</version>
            </dependency>
            <dependency>
                <groupId>com.atlassian.qunit</groupId>
                <artifactId>atlassian-qunit-plugin-util</artifactId>
                <version>${atlassian.qunit.plugin.version}</version>
            </dependency>
            <dependency>
                <groupId>com.sun.jersey</groupId>
                <artifactId>jersey-client</artifactId>
                <version>1.19.4</version>
            </dependency>
            <dependency>
                <groupId>commons-beanutils</groupId>
                <artifactId>commons-beanutils</artifactId>
                <version>1.9.4</version>
            </dependency>
            <dependency>
                <groupId>junit</groupId>
                <artifactId>junit</artifactId>
                <version>4.13.2</version>
            </dependency>
            <dependency>
                <groupId>net.sourceforge.htmlunit</groupId>
                <artifactId>htmlunit</artifactId>
                <version>2.51.0</version>
            </dependency>
            <dependency>
                <groupId>org.apache.commons</groupId>
                <artifactId>commons-compress</artifactId>
                <version>1.21</version>
            </dependency>
            <dependency>
                <groupId>org.codehaus.httpcache4j.resolvers</groupId>
                <artifactId>resolvers-httpcomponents-httpclient</artifactId>
                <version>${httpcache4j.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>commons-logging</groupId>
                        <artifactId>commons-logging</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.apache.httpcomponents</groupId>
                        <artifactId>httpclient</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>org.codehaus.jackson</groupId>
                <artifactId>jackson-core-asl</artifactId>
                <version>1.9.14-atlassian-6</version>
            </dependency>
            <dependency>
                <groupId>org.hamcrest</groupId>
                <artifactId>hamcrest-core</artifactId>
                <version>${hamcrest.version}</version>
            </dependency>
            <dependency>
                <groupId>org.hamcrest</groupId>
                <artifactId>hamcrest-library</artifactId>
                <version>${hamcrest.version}</version>
            </dependency>
            <dependency>
                <groupId>org.mockito</groupId>
                <artifactId>mockito-core</artifactId>
                <version>1.10.19</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.jacoco</groupId>
                    <artifactId>jacoco-maven-plugin</artifactId>
                    <version>0.8.7</version>
                </plugin>
                <plugin>
                    <groupId>org.sonarsource.scanner.maven</groupId>
                    <artifactId>sonar-maven-plugin</artifactId>
                    <version>3.9.0.2155</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-dependency-plugin</artifactId>
                    <version>3.6.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <configuration>
                        <argLine>${jvm.opens}</argLine>
                        <includes>
                            <include>**/*Test.java</include>
                        </includes>
                        <excludes>
                            <exclude>it/**/*</exclude>
                            <exclude>**/*$*</exclude>
                        </excludes>
                        <trimStackTrace>false</trimStackTrace>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <configuration>
                        <argLine>${jvm.opens}</argLine>
                        <trimStackTrace>false</trimStackTrace>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>gr.abiss.mvn.plugins</groupId>
                    <artifactId>maven-jstools-plugin</artifactId>
                    <version>0.7-atlassian-1</version>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>amps-maven-plugin</artifactId>
                    <version>${amps.version}</version>
                    <configuration>
                        <extractDependencies>false</extractDependencies>
                        <skipManifestValidation>true</skipManifestValidation>
                        <encoding>UTF-8</encoding>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>refapp-maven-plugin</artifactId>
                    <version>${amps.version}</version>
                    <extensions>true</extensions>
                    <configuration>
                        <extractDependencies>false</extractDependencies>
                        <!-- TODO remove plugin-data-editor version override once AMPS will provide it -->
                        <pdeVersion>1.5.2</pdeVersion>
                        <skipManifestValidation>true</skipManifestValidation>
                        <server>localhost</server>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.plugin</groupId>
                    <artifactId>atlassian-spring-scanner-maven-plugin</artifactId>
                    <version>${atlassian.spring.scanner.version}</version>
                    <executions>
                        <execution>
                            <goals>
                                <goal>atlassian-spring-scanner</goal>
                            </goals>
                            <phase>process-classes</phase>
                        </execution>
                    </executions>
                    <configuration>
                        <verbose>true</verbose>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-enforcer-plugin</artifactId>
                    <executions>
                        <execution>
                            <id>ban-milestones-and-release-candidates</id>
                            <phase>validate</phase>
                            <goals>
                                <goal>enforce</goal>
                            </goals>
                            <configuration>
                                <rules>
                                    <banVersionDeps>
                                        <excludes>
                                            <exclude>com.atlassian.selenium:atlassian-pageobjects-elements</exclude>
                                            <exclude>com.atlassian.selenium:atlassian-pageobjects-api</exclude>
                                        </excludes>
                                    </banVersionDeps>
                                </rules>
                            </configuration>
                        </execution>
                        <execution>
                            <id>enforce-bouncycastle</id>
                            <goals>
                                <goal>enforce</goal>
                            </goals>
                            <phase>validate</phase>
                            <configuration>
                                <rules>
                                    <bannedDependencies>
                                        <searchTransitive>true</searchTransitive>
                                        <message>make sure bouncycastle is not on the classpath</message>
                                        <excludes>
                                            <exclude>*bouncycastle:*</exclude>
                                        </excludes>
                                    </bannedDependencies>
                                </rules>
                                <fail>false</fail>
                            </configuration>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>com.github.eirslett</groupId>
                    <artifactId>frontend-maven-plugin</artifactId>
                    <version>${frontend-maven-plugin.version}</version>
                    <configuration>
                        <nodeVersion>${frontend-maven-plugin.node.version}</nodeVersion>
                        <yarnVersion>${frontend-maven-plugin.yarn.version}</yarnVersion>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-failsafe-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>com.diffplug.spotless</groupId>
                <artifactId>spotless-maven-plugin</artifactId>
                <version>2.43.0</version>
                <configuration>
                    <java>
                        <palantirJavaFormat>
                            <version>2.39.0</version>
                        </palantirJavaFormat>
                        <importOrder>
                            <wildcardsLast>true</wildcardsLast>
                            <order>java|javax,lombok,org.spring|org|com|io,,com.atlassian,com.atlassian.beacon|\#,\#com.atlassian</order>
                        </importOrder>
                        <removeUnusedImports />
                    </java>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>release</id>
            <properties>
                <skipTests>true</skipTests>
            </properties>
        </profile>
        <profile>
            <id>jacoco</id>
            <properties>
                <jacoco.include.pattern>com/atlassian/gadgets/**</jacoco.include.pattern>
            </properties>
            <build>
                <plugins>
                    <!-- Code coverage -->
                    <plugin>
                        <groupId>org.jacoco</groupId>
                        <artifactId>jacoco-maven-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>agent-for-ut</id>
                                <goals>
                                    <goal>prepare-agent</goal>
                                </goals>
                                <configuration>
                                    <propertyName>jacoco.agent.argLine</propertyName>
                                    <includes>
                                        <include>${jacoco.include.pattern}</include>
                                    </includes>
                                </configuration>
                            </execution>
                            <execution>
                                <id>agent-for-it</id>
                                <phase>initialize</phase>
                                <goals>
                                    <goal>prepare-agent-integration</goal>
                                </goals>
                                <configuration>
                                    <propertyName>jacoco.agent.it.argLine</propertyName>
                                    <includes>
                                        <include>${jacoco.include.pattern}</include>
                                    </includes>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-surefire-plugin</artifactId>
                        <configuration>
                            <argLine>${jvm.opens} @{jacoco.agent.argLine}</argLine>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-failsafe-plugin</artifactId>
                        <configuration>
                            <argLine>${jvm.opens} @{jacoco.agent.argLine}</argLine>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
