<!--

    Copyright (c) 2011, 2024 Oracle and/or its affiliates. All rights reserved.

    This program and the accompanying materials are made available under the
    terms of the Eclipse Distribution License v. 1.0, which is available at
    http://www.eclipse.org/org/documents/edl-v10.php.

    SPDX-License-Identifier: BSD-3-Clause

-->

<!-- steps to release give all of them together in one command : mvn release:clean release:prepare release:perform -->
<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>org.eclipse.ee4j</groupId>
        <artifactId>project</artifactId>
        <version>1.0.9</version>
        <relativePath/>
    </parent>

    <groupId>com.sun.xml.messaging.saaj</groupId>
    <artifactId>metro-saaj</artifactId>
    <version>3.0.4</version>
    <packaging>pom</packaging>

    <name>Jakarta SOAP</name>
    <description>
        Implementation of Jakarta SOAP with Attachments Specification
    </description>

    <scm>
        <connection>scm:git:git@github.com:eclipse-ee4j/metro-saaj.git</connection>
        <developerConnection>scm:git:git@github.com:eclipse-ee4j/metro-saaj.git</developerConnection>
        <url>https://github.com/eclipse-ee4j/metro-saaj</url>
        <tag>HEAD</tag>
    </scm>

    <licenses>
        <license>
            <name>Eclipse Distribution License - v 1.0</name>
            <url>http://www.eclipse.org/org/documents/edl-v10.php</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <developers>
        <developer>
            <id>lukasj</id>
            <name>Lukas Jungmann</name>
            <email>Lukas.Jungmann@oracle.com</email>
        </developer>
        <developer>
            <id>bravehorsie</id>
            <name>Roman Grigoriadi</name>
        </developer>
    </developers>

    <issueManagement>
        <system>IssueTracker</system>
        <url>https://github.com/eclipse-ee4j/metro-saaj/issues</url>
    </issueManagement>

    <mailingLists>
        <mailingList>
            <name>Metro mailing list</name>
            <post>metro-dev@eclipse.org</post>
            <subscribe>https://accounts.eclipse.org/mailing-list/metro-dev</subscribe>
            <unsubscribe>https://accounts.eclipse.org/mailing-list/metro-dev</unsubscribe>
            <archive>https://www.eclipse.org/lists/metro-dev</archive>
        </mailingList>
    </mailingLists>

    <properties>
        <project.build.commonResourcesDirectory>${project.build.directory}/common-resources</project.build.commonResourcesDirectory>
        <legal.doc.source>${project.build.commonResourcesDirectory}/legal</legal.doc.source>
        <copyright.exclude>${project.build.commonResourcesDirectory}/config/copyright-exclude</copyright.exclude>
        <copyright.ignoreyear>false</copyright.ignoreyear>
        <copyright.scmonly>true</copyright.scmonly>
        <copyright.template>${project.build.commonResourcesDirectory}/config/edl-copyright.txt</copyright.template>
        <copyright.update>false</copyright.update>
        <spotbugs.exclude>${project.build.commonResourcesDirectory}/config/exclude.xml</spotbugs.exclude>
        <spotbugs.skip>false</spotbugs.skip>
        <spotbugs.threshold>Low</spotbugs.threshold>
        <spotbugs.version>4.8.3.1</spotbugs.version>
        <findsecbugs.version>1.11.0</findsecbugs.version>

        <maven.compiler.release>11</maven.compiler.release>
        <maven.compiler.testRelease>${maven.compiler.release}</maven.compiler.testRelease>
        <!-- exclude big groups from the Xlint -->
        <comp.xlint>-Xlint:all,-rawtypes</comp.xlint>
        <!-- -Xdoclint:-missing does not seem to work properly on the infra -->
        <comp.xdoclint>-Xdoclint:all,-missing</comp.xdoclint>
        <warn.limit>150</warn.limit>
        <jdoc.doclint>-missing</jdoc.doclint>

        <activation-api.version>2.1.3</activation-api.version>
        <angus-activation.version>2.0.2</angus-activation.version>

        <xml.bind-api.version>4.0.2</xml.bind-api.version>
        <xml.soap-api.version>3.0.2</xml.soap-api.version>

        <fastinfoset.version>2.1.1</fastinfoset.version>
        <mimepull.version>1.10.0</mimepull.version>
        <stax-ex.version>2.1.0</stax-ex.version>
        <junit.version>4.13.2</junit.version>
        <saaj.version>${project.version}</saaj.version>
        <saaj.javadoc.source>${maven.compiler.release}</saaj.javadoc.source>
        <saaj.javadoc.source>11</saaj.javadoc.source>
        <saaj.javadoc.title>Eclipse SAAJ API documentation</saaj.javadoc.title>
        <saaj.javadoc.header><![CDATA[<br>Eclipse SAAJ v${saaj.version}]]></saaj.javadoc.header>
        <saaj.javadoc.bottom><![CDATA[
Comments to: <a href="mailto:metro-dev@eclipse.org">metro-dev@eclipse.org</a>.<br>
Copyright &#169; 2018, ${current.year} Eclipse Foundation. All rights reserved.]]></saaj.javadoc.bottom>
    </properties>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>buildnumber-maven-plugin</artifactId>
                    <version>3.2.0</version>
                </plugin>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>build-helper-maven-plugin</artifactId>
                    <version>3.5.0</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-resources-plugin</artifactId>
                    <version>3.3.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>3.12.1</version>
                </plugin>
                <plugin>
                    <groupId>org.glassfish.copyright</groupId>
                    <artifactId>glassfish-copyright-maven-plugin</artifactId>
                    <version>2.4</version>
                    <configuration>
                        <templateFile>${copyright.template}</templateFile>
                        <excludeFile>${copyright.exclude}</excludeFile>
                        <scmOnly>${copyright.scmonly}</scmOnly>
                        <update>${copyright.update}</update>
                        <ignoreYear>${copyright.ignoreyear}</ignoreYear>
                        <quiet>false</quiet>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>com.github.spotbugs</groupId>
                    <artifactId>spotbugs-maven-plugin</artifactId>
                    <version>${spotbugs.version}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>3.2.5</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.felix</groupId>
                    <artifactId>maven-bundle-plugin</artifactId>
                    <version>5.1.9</version>
                    <configuration>
                        <niceManifest>true</niceManifest>
                        <instructions>
                            <_noextraheaders>true</_noextraheaders>
                        </instructions>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>3.3.0</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>3.2.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>3.6.3</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-enforcer-plugin</artifactId>
                    <version>3.4.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-deploy-plugin</artifactId>
                    <version>3.1.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <version>3.2.5</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-assembly-plugin</artifactId>
                    <version>3.6.0</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-antrun-plugin</artifactId>
                    <version>3.1.0</version>
                </plugin>
            </plugins>
        </pluginManagement>

        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-enforcer-plugin</artifactId>
                <executions>
                    <execution>
                        <id>enforce-maven</id>
                        <goals>
                            <goal>enforce</goal>
                        </goals>
                        <configuration>
                            <rules>
                                <requireJavaVersion>
                                    <version>[11,)</version>
                                </requireJavaVersion>
                                <requireMavenVersion>
                                    <version>[3.6.0,)</version>
                                </requireMavenVersion>
                            </rules>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>add-legal-resource</id>
                        <phase>generate-resources</phase>
                        <goals>
                            <goal>add-resource</goal>
                        </goals>
                        <configuration>
                            <resources>
                                <resource>
                                    <directory>${legal.doc.source}</directory>
                                    <targetPath>META-INF</targetPath>
                                </resource>
                            </resources>
                        </configuration>
                    </execution>
                    <execution>
                        <id>current-year-property</id>
                        <goals>
                            <goal>timestamp-property</goal>
                        </goals>
                        <phase>validate</phase>
                        <configuration>
                            <name>current.year</name>
                            <locale>en,US</locale>
                            <pattern>yyyy</pattern>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>buildnumber-maven-plugin</artifactId>
                <configuration>
                    <getRevisionOnlyOnce>true</getRevisionOnlyOnce>
                    <shortRevisionLength>7</shortRevisionLength>
                    <revisionOnScmFailure>false</revisionOnScmFailure>
                </configuration>
                <executions>
                    <execution>
                        <phase>validate</phase>
                        <goals>
                            <goal>create</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-assembly-plugin</artifactId>
                <executions>
                    <execution>
                        <id>common-resources</id>
                        <phase>generate-resources</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                        <inherited>false</inherited>
                        <configuration>
                            <descriptors>
                                <descriptor>src/main/assembly/resources.xml</descriptor>
                            </descriptors>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <executions>
                    <execution>
                        <id>unpack-resource</id>
                        <phase>generate-resources</phase>
                        <goals>
                            <goal>unpack</goal>
                        </goals>
                        <configuration>
                            <artifactItems>
                                <artifactItem>
                                    <groupId>com.sun.xml.messaging.saaj</groupId>
                                    <artifactId>metro-saaj</artifactId>
                                    <version>${project.version}</version>
                                    <classifier>resources</classifier>
                                    <type>zip</type>
                                    <outputDirectory>${project.build.commonResourcesDirectory}</outputDirectory>
                                </artifactItem>
                            </artifactItems>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>com.github.spotbugs</groupId>
                <artifactId>spotbugs-maven-plugin</artifactId>
                <configuration>
                    <skip>${spotbugs.skip}</skip>
                    <threshold>${spotbugs.threshold}</threshold>
                    <excludeFilterFile>
                        ${spotbugs.exclude}
                    </excludeFilterFile>
                    <plugins>
                        <plugin>
                            <groupId>com.h3xstream.findsecbugs</groupId>
                            <artifactId>findsecbugs-plugin</artifactId>
                            <version>${findsecbugs.version}</version>
                        </plugin>
                    </plugins>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.owasp</groupId>
                <artifactId>dependency-check-maven</artifactId>
                <version>9.0.9</version>
                <configuration>
                    <failBuildOnCVSS>7</failBuildOnCVSS>
                    <assemblyAnalyzerEnabled>false</assemblyAnalyzerEnabled>
                    <formats>
                        <format>HTML</format>
                        <format>CSV</format>
                    </formats>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>jakarta.activation</groupId>
                <artifactId>jakarta.activation-api</artifactId>
                <version>${activation-api.version}</version>
            </dependency>
            <dependency>
                <groupId>org.eclipse.angus</groupId>
                <artifactId>angus-activation</artifactId>
                <version>${angus-activation.version}</version>
            </dependency>
            <dependency>
                <groupId>jakarta.xml.bind</groupId>
                <artifactId>jakarta.xml.bind-api</artifactId>
                <version>${xml.bind-api.version}</version>
            </dependency>
            <dependency>
                <groupId>jakarta.xml.soap</groupId>
                <artifactId>jakarta.xml.soap-api</artifactId>
                <version>${xml.soap-api.version}</version>
            </dependency>
            <dependency>
                <groupId>org.jvnet.mimepull</groupId>
                <artifactId>mimepull</artifactId>
                <version>${mimepull.version}</version>
            </dependency>
            <dependency>
                <groupId>org.jvnet.staxex</groupId>
                <artifactId>stax-ex</artifactId>
                <version>${stax-ex.version}</version>
            </dependency>
            <dependency>
                <groupId>junit</groupId>
                <artifactId>junit</artifactId>
                <version>${junit.version}</version>
            </dependency>
            <dependency>
                <groupId>com.sun.xml.fastinfoset</groupId>
                <artifactId>FastInfoset</artifactId>
                <version>${fastinfoset.version}</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <modules>
        <module>saaj-ri</module>
    </modules>

    <profiles>
        <profile>
            <id>samples</id>
            <modules>
                <module>saaj-samples</module>
                <module>docs</module>
            </modules>
        </profile>
        <profile>
            <id>spotbugs</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>com.github.spotbugs</groupId>
                        <artifactId>spotbugs-maven-plugin</artifactId>
                        <executions>
                            <execution>
                                <phase>verify</phase>
                                <goals>
                                    <goal>spotbugs</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>dependency-check</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.owasp</groupId>
                        <artifactId>dependency-check-maven</artifactId>
                        <executions>
                            <execution>
                                <goals>
                                    <goal>check</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
