<?xml version="1.0" encoding="UTF-8"?>
<!--

    Copyright 2017 Goldman Sachs.
    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing,
    software distributed under the License is distributed on an
    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
    KIND, either express or implied.  See the License for the
    specific language governing permissions and limitations
    under the License.

-->
<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>

    <groupId>com.goldmansachs.obevo</groupId>
    <artifactId>obevo-parent</artifactId>
    <version>6.5.0</version>
    <packaging>pom</packaging>

    <modules>
        <module>obevo-dists</module>
        <module>obevo-utils</module>
        <module>obevo-dbmetadata-impl</module>
        <module>obevo-core</module>
        <module>obevo-db</module>
        <module>obevo-db-impls</module>
        <module>obevo-internal-comparer</module>
        <module>obevo-site</module>
        <module>obevo-internal-test-client-01</module>
        <module>obevo-internal-test-client-02</module>
        <module>obevo-internal-test-util</module>  <!-- put bom at the end as the last module of the staging plugin must be deployed for all the eligible modules to get deployed -->
        <module>obevo-bom</module>
        <module>obevo-dependencies</module>
        <module>obevo-mongodb</module>
    </modules>

    <name>Obevo Parent POM</name>
    <description>Obevo is a utility to facilitate deployments on stateful and stateless environment types, notably databases.</description>
    <url>https://github.com/goldmansachs/obevo/</url>
    <inceptionYear>2017</inceptionYear>

    <organization>
        <name>Goldman Sachs</name>
        <url>http://www.goldmansachs.com/</url>
    </organization>

    <!--
    Note on acceptable licenses to Apache products: https://www.apache.org/legal/resolved.html
    -->
    <licenses>
        <license>
            <name>The Apache License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        </license>
    </licenses>

    <developers>
        <developer>
            <name>Shant Stepanian</name>
            <email>shant.stepanian@gs.com</email>
            <organization>Goldman Sachs</organization>
        </developer>
    </developers>

    <scm>
        <url>https://github.com/goldmansachs/obevo/</url>
        <connection>scm:git:https://github.com/goldmansachs/obevo.git</connection>
        <developerConnection>scm:git:https://github.com/goldmansachs/obevo.git</developerConnection>
        <tag>6.5.0</tag>
    </scm>


    <issueManagement>
        <system>GitHub</system>
        <url>https://github.com/goldmansachs/obevo/issues</url>
    </issueManagement>


    <ciManagement>
        <system>Travis CI</system>
        <url>https://travis-ci.org/goldmansachs/obevo</url>
    </ciManagement>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <!--
                <repository>
                    <id>ossrh</id>
                    <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
                </repository>
        -->
    </distributionManagement>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

        <!-- sharing common build files using mechanism described here: http://javasplitter.blogspot.com/2011/08/sharing-configuration-files-from-maven.html -->
        <build-resources.classifier>build-resources</build-resources.classifier>
        <build-resources.workdir>${basedir}/target/${build-resources.classifier}</build-resources.workdir>

        <!-- common dependency version properties -->
        <slf4j.version>1.7.18</slf4j.version>
        <eclipsecollections.version>7.0.2</eclipsecollections.version>

        <extra-enforcer-rules.version>1.0-beta-6</extra-enforcer-rules.version>

        <sonar.exclusions>file:**/generated-sources/**/*</sonar.exclusions>
        <dbCredsFile />  <!-- empty by default -->
    </properties>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>com.mycila</groupId>
                    <artifactId>license-maven-plugin</artifactId>
                    <version>3.0</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.rat</groupId>
                    <artifactId>apache-rat-plugin</artifactId>
                    <version>0.12</version>
                </plugin>
                <plugin>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>2.3.2</version>
                </plugin>
                <plugin>
                    <artifactId>maven-site-plugin</artifactId>
                    <version>3.3</version>
                </plugin>
                <plugin>
                    <artifactId>maven-dependency-plugin</artifactId>
                    <version>2.8</version>
                </plugin>
                <plugin>
                    <artifactId>maven-assembly-plugin</artifactId>
                    <version>3.0.0</version>
                </plugin>
                <plugin>
                    <artifactId>maven-clean-plugin</artifactId>
                    <version>2.5</version>
                </plugin>
                <plugin>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <version>2.19.1</version>
                </plugin>
                <plugin>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.19.1</version>
                    <configuration>
                        <!--<jvm>/Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home/bin/java</jvm>-->
                        <!--<jvm>/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin/java</jvm>-->
                        <jvm>${env.JAVA7_HOME}/bin/java</jvm>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.jacoco</groupId>
                    <artifactId>jacoco-maven-plugin</artifactId>
                    <version>0.7.2.201409121644</version>
                </plugin>
                <plugin>
                    <artifactId>maven-install-plugin</artifactId>
                    <version>2.4</version>
                </plugin>
                <plugin>
                    <artifactId>maven-checkstyle-plugin</artifactId>
                    <version>2.17</version>
                </plugin>
                <plugin>
                    <artifactId>maven-deploy-plugin</artifactId>
                    <version>2.7</version>
                </plugin>
                <plugin>
                    <artifactId>maven-resources-plugin</artifactId>
                    <version>2.6</version>
                </plugin>
                <plugin>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>2.2</version>
                </plugin>
                <plugin>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>2.10.4</version>
                </plugin>
                <plugin>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>2.5</version>
                </plugin>
                <plugin>
                    <artifactId>maven-enforcer-plugin</artifactId>
                    <version>1.4.1</version>
                </plugin>
                <plugin>
                    <groupId>org.jasig.maven</groupId>
                    <artifactId>maven-notice-plugin</artifactId>
                    <version>1.1.0</version>
                </plugin>
            </plugins>
        </pluginManagement>

        <plugins>
            <plugin>
                <artifactId>maven-release-plugin</artifactId>
                <version>2.5.3</version>
                <configuration>
                    <autoVersionSubmodules>true</autoVersionSubmodules>
                    <useReleaseProfile>false</useReleaseProfile>
                    <releaseProfiles>release</releaseProfiles>
                    <tagNameFormat>@{project.version}</tagNameFormat>
                    <goals>deploy</goals>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <source>1.8</source>
                    <target>1.8</target>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-surefire-plugin</artifactId>
                <configuration>
                    <systemProperties>
                        <dbCredsFile>${dbCredsFile}</dbCredsFile>
                    </systemProperties>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-failsafe-plugin</artifactId>
                <executions>
                    <execution>
                        <id>integration-tests</id>
                        <goals>
                            <goal>integration-test</goal>
                            <goal>verify</goal>
                        </goals>
                        <configuration>
                            <systemProperties>
                                <dbCredsFile>${dbCredsFile}</dbCredsFile>
                            </systemProperties>
                            <!-- specifying the alphabetical run order for now to work through the use case of
                            ASE tests executing before IQ tests as the JDBC4 driver should get loaded first
                            before JDBC 3 for both those tests to work -->
                            <runOrder>alphabetical</runOrder>
                            <argLine>-Xmx1024m -XX:MaxPermSize=256m ${jacoco.agent.it.arg}</argLine>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>pre-integration-test</id>
                        <phase>pre-integration-test</phase>
                        <goals>
                            <goal>prepare-agent</goal>
                        </goals>
                        <configuration>
                            <destFile>${sonar.jacoco.itReportPath}</destFile>
                            <propertyName>jacoco.agent.it.arg</propertyName>
                            <append>true</append>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <artifactId>maven-deploy-plugin</artifactId>
            </plugin>
            <plugin>
                <artifactId>maven-resources-plugin</artifactId>
            </plugin>

            <plugin>
                <artifactId>maven-source-plugin</artifactId>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar-no-fork</goal>
                            <goal>test-jar-no-fork</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <artifactId>maven-jar-plugin</artifactId>
                <executions>
                    <execution>
                        <goals>
                            <goal>test-jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <artifactId>maven-enforcer-plugin</artifactId>
                <executions>
                    <execution>
                        <id>enforce-non-duplicate-dependencies</id>
                        <goals>
                            <goal>enforce</goal>
                        </goals>
                        <configuration>
                            <rules>
                                <banDuplicateClasses>
                                    <dependencies>
                                        <dependency>
                                            <artifactId>commons-beanutils</artifactId>
                                            <ignoreClasses>
                                                <ignoreClass>org/apache/commons/collections/*</ignoreClass>
                                            </ignoreClasses>
                                        </dependency>
                                        <dependency>
                                            <artifactId>commons-collections</artifactId>
                                            <ignoreClasses>
                                                <ignoreClass>org/apache/commons/collections/*</ignoreClass>
                                            </ignoreClasses>
                                        </dependency>
                                        <dependency>
                                            <groupId>com.sybase.jdbcx</groupId>
                                            <artifactId>jconn3</artifactId>
                                            <ignoreClasses>
                                                <ignoreClass>com/sybase/jdbcx/*</ignoreClass>
                                                <ignoreClass>SybVersion</ignoreClass>
                                            </ignoreClasses>
                                        </dependency>
                                        <dependency>
                                            <groupId>com.sybase.jdbcx</groupId>
                                            <artifactId>jconn4</artifactId>
                                            <ignoreClasses>
                                                <ignoreClass>com/sybase/jdbcx/*</ignoreClass>
                                                <ignoreClass>SybVersion</ignoreClass>
                                            </ignoreClasses>
                                        </dependency>
                                    </dependencies>
                                    <findAllDuplicates>true</findAllDuplicates>
                                </banDuplicateClasses>
                                <reactorModuleConvergence />
                                <requireJavaVersion>
                                    <version>1.6.0</version>
                                </requireJavaVersion>
                                <requireMavenVersion>
                                    <version>3.2.5</version>
                                </requireMavenVersion>
                            </rules>
                            <fail>true</fail>
                        </configuration>
                    </execution>
                    <execution>
                        <!-- Keep dependency convergence as a separate execution so that certain child modules can override it if needed (e.g. maven plugin modules) -->
                        <id>enforce-dependency-convergence</id>
                        <goals>
                            <goal>enforce</goal>
                        </goals>
                        <configuration>
                            <rules>
                                <dependencyConvergence />
                            </rules>
                            <fail>true</fail>
                        </configuration>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>org.codehaus.mojo</groupId>
                        <artifactId>extra-enforcer-rules</artifactId>
                        <version>${extra-enforcer-rules.version}</version>
                    </dependency>
                </dependencies>
            </plugin>

            <plugin>
                <!-- We want to package up license resources in the JARs produced; borrowed from Apache convention (e.g. Apache Curator) -->
                <artifactId>maven-remote-resources-plugin</artifactId>
                <version>1.5</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>process</goal>
                        </goals>
                        <configuration>
                            <resourceBundles>
                                <resourceBundle>org.apache:apache-jar-resource-bundle:1.4</resourceBundle>
                            </resourceBundles>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <!-- Using apache-rat-plugin to check that the license files are applied correctly. This is used by
                 many Apache-licensed projects for validation; hence we use it here. -->
                <groupId>org.apache.rat</groupId>
                <artifactId>apache-rat-plugin</artifactId>
                <configuration>
                    <addLicenseHeaders>false</addLicenseHeaders>
                    <copyrightMessage>Copyright 2017 Goldman Sachs.</copyrightMessage>
                    <excludes>
                        <!-- Standard project files to exclude -->
                        <exclude>**/.idea/**</exclude>
                        <exclude>**/.travis.yml</exclude>
                        <exclude>**/BUILD.md</exclude>
                        <exclude>**/CHANGELOG.md</exclude>
                        <exclude>**/CONTRIBUTING.md</exclude>
                        <exclude>**/CODE_OF_CONDUCT.md</exclude>
                        <exclude>**/ISSUE_TEMPLATE.md</exclude>
                        <exclude>**/PULL_REQUEST_TEMPLATE.md</exclude>
                        <exclude>**/LICENSE.txt</exclude>
                        <exclude>**/NOTICE.txt</exclude>
                        <exclude>**/NOTICE.template.txt</exclude>
                        <exclude>**/README.md</exclude>

                        <!-- Excluding the reverse-engineering files  -->
                        <exclude>**/test/resources/**/reveng/**</exclude>
                        <exclude>**/test/resources/**/expected/**</exclude>

                        <!-- Other SP/sql files to exclude that weren't automatically applied by the mycila plugin originally -->
                        <exclude>**/*.ddl</exclude>
                        <exclude>**/*.spc</exclude>
                        <exclude>**/*.csv</exclude>
                        <exclude>**/vfs/FileObject/*</exclude>

                        <!-- Excluding CATO files -->
                        <exclude>**/src/test/resources/csv-file.txt</exclude>
                        <exclude>**/src/test/resources/testdata1.txt</exclude>
                        <exclude>**/src/test/resources/testdata2.txt</exclude>
                        <exclude>**/src/test/resources/testdata3.txt</exclude>
                        <exclude>**/src/test/resources/testdb.ddl</exclude>
                    </excludes>
                </configuration>
                <executions>
                    <execution>
                        <id>run-rat-check</id>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>animal-sniffer-maven-plugin</artifactId>
                <version>1.16</version>
                <configuration>
                    <signature>
                        <groupId>org.codehaus.mojo.signature</groupId>
                        <artifactId>java17</artifactId>
                        <version>1.0</version>
                    </signature>
                </configuration>
                <executions>
                    <execution>
                        <id>verify</id>
                        <phase>package</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>


            <plugin>
                <!-- sharing common build files using mechanism described here: http://javasplitter.blogspot.com/2011/08/sharing-configuration-files-from-maven.html -->
                <artifactId>maven-assembly-plugin</artifactId>
                <executions>
                    <execution>
                        <id>make-build-resources</id>
                        <inherited>false</inherited>  <!-- we only publish the common files in the module root -->
                        <phase>validate</phase>  <!-- Should be first step in sharing common build files -->
                        <goals>
                            <goal>single</goal>
                        </goals>
                        <configuration>
                            <descriptors>
                                <descriptor>src/main/assembly/${build-resources.classifier}.xml</descriptor>
                            </descriptors>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <!-- Keep this plugin defined under plugins (even if no executions below) as a convenience for developers to run utilities like dependency:tree in IntelliJ -->
                <artifactId>maven-dependency-plugin</artifactId>
                <executions>
                    <execution>
                        <id>unpack-build-resources</id>
                        <phase>initialize</phase>  <!-- Should be first step in sharing common build files after make-build-resources -->
                        <goals>
                            <goal>unpack</goal>
                        </goals>
                        <configuration>
                            <artifactItems>
                                <artifactItem>
                                    <groupId>com.goldmansachs.obevo</groupId>
                                    <artifactId>obevo-parent</artifactId>
                                    <version>${project.version}</version>
                                    <type>jar</type>
                                    <classifier>build-resources</classifier>
                                    <overWrite>true</overWrite>
                                    <outputDirectory>${basedir}/target/build-resources</outputDirectory>
                                </artifactItem>
                            </artifactItems>
                            <includes>**/*</includes>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.jasig.maven</groupId>
                <artifactId>maven-notice-plugin</artifactId>
                <configuration>
                    <noticeTemplate>${build-resources.workdir}/NOTICE.template.txt</noticeTemplate>
                    <licenseMapping>
                        <param>${build-resources.workdir}/license-mappings.xml</param>
                    </licenseMapping>
                    <fileName>NOTICE.txt</fileName>
                    <includeChildDependencies>false</includeChildDependencies>
                    <includeScopes>
                        <includeScopes>compile</includeScopes>
                        <includeScopes>runtime</includeScopes>
                    </includeScopes>
                    <excludeOptional>true</excludeOptional>
                </configuration>
                <executions>
                    <execution>
                        <id>check-license</id>
                        <phase>process-sources</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <executions>
                    <execution>
                        <goals>
                            <goal>check</goal>
                        </goals>
                        <configuration>
                            <configLocation>${build-resources.workdir}/checkstyle.xml</configLocation>
                            <logViolationsToConsole>true</logViolationsToConsole>
                            <propertyExpansion>import-control.directory=${build-resources.workdir}</propertyExpansion>
                            <failOnViolation>true</failOnViolation>
                            <excludes />
                            <excludes>**/sqlparser/**/*,**/HelpMojo*</excludes>
                        </configuration>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>com.puppycrawl.tools</groupId>
                        <artifactId>checkstyle</artifactId>
                        <version>6.19</version>  <!-- Get latest checkstyle version on Java 7 -->
                    </dependency>
                </dependencies>
            </plugin>

            <plugin>
                <groupId>net.orfjackal.retrolambda</groupId>
                <artifactId>retrolambda-maven-plugin</artifactId>
                <version>2.5.3</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>process-main</goal>
                            <goal>process-test</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <target>1.7</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
                <version>0.8.0</version>
                <executions>
                    <execution>
                        <id>default-prepare-agent</id>
                        <goals>
                            <goal>prepare-agent</goal>
                        </goals>
                    </execution>
                    <execution>
                        <id>default-report</id>
                        <goals>
                            <goal>report</goal>
                        </goals>
                    </execution>
                    <execution>
                        <id>default-check</id>
                        <goals>
                            <goal>check</goal>
                        </goals>
                        <configuration>
                            <rules>
                                <rule>
                                    <element>BUNDLE</element>
                                    <!--
                                                                        <limits>
                                                                            <limit>
                                                                                <counter>COMPLEXITY</counter>
                                                                                <value>COVEREDRATIO</value>
                                                                                <minimum>0.25</minimum>
                                                                            </limit>
                                                                        </limits>
                                    -->
                                </rule>
                            </rules>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <reporting>
        <plugins>
            <plugin>
                <artifactId>maven-project-info-reports-plugin</artifactId>
                <version>2.9</version>
            </plugin>
        </plugins>
    </reporting>

    <profiles>
        <profile>
            <id>release</id>
            <properties>
                <skipTests>true</skipTests>
            </properties>
            <build>
                <plugins>
                    <plugin>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <version>1.6.7</version>
                        <extensions>true</extensions>
                        <configuration>
                            <serverId>ossrh</serverId>
                            <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                        </configuration>
                    </plugin>
                    <plugin>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>1.6</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <!-- Use this profile to bulk-apply the NOTICE -->
            <id>update-notice-files</id>
            <build>
                <plugins>
                    <plugin>
                        <!-- Generate the license header in each file.
                        We can use apache-rat-plugin to apply the license using the settings below to override the main plugin configuration.
                        However, it isn't as good at applying the license to existing files. For that, we delegate to
                        mycila's license-maven-plugin
                        -->
                        <groupId>org.apache.rat</groupId>
                        <artifactId>apache-rat-plugin</artifactId>
                        <configuration>
                            <addLicenseHeaders>forced</addLicenseHeaders>
                            <ignoreErrors>true</ignoreErrors>
                        </configuration>
                    </plugin>

                    <!-- Generate the NOTICE.txt files -->
                    <plugin>
                        <groupId>org.jasig.maven</groupId>
                        <artifactId>maven-notice-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>generate-license</id>
                                <phase>generate-sources</phase>
                                <goals>
                                    <goal>generate</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>

                </plugins>
            </build>
        </profile>
        <profile>
            <!-- Use this profile to bulk-apply the license headers -->
            <id>update-license-headers</id>
            <build>
                <plugins>
                    <plugin>
                        <!-- Generate the license header in each file.
                        The mycila plugin is a bit friendlier to apply the plugin, e.g. it was able to add it to
                        sql files, where the rat plugin would not. Hence, we include it here for this profile.
                        We don't use it for the validation itself as 1) it is unnecessarily unfriendly when it comes to
                        whitespace in comparing the license headers  2) we'd rather use apache-rat-plugin that is used
                        by more projects -->
                        <groupId>com.mycila</groupId>
                        <artifactId>license-maven-plugin</artifactId>
                        <configuration>
                            <inlineHeader><![CDATA[Copyright ${project.inceptionYear} Goldman Sachs.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied.  See the License for the
specific language governing permissions and limitations
under the License.]]></inlineHeader>
                            <excludes>
                                <!-- Standard project files to exclude -->
                                <exclude>**/.idea/**</exclude>
                                <exclude>**/CHANGELOG.md</exclude>
                                <exclude>**/LICENSE.txt</exclude>
                                <exclude>**/NOTICE.txt</exclude>
                                <exclude>**/NOTICE.template.txt</exclude>
                                <exclude>**/README.md</exclude>

                                <!-- Excluding the reverse-engineering files  -->
                                <exclude>**/test/resources/**/reveng/**</exclude>

                                <!-- Files from other Apache projects that were modified and should keep original Apache license notice -->
                                <exclude>**/com/gs/obevo/db/apps/reveng/CSVWriter.java</exclude>
                                <exclude>**/com/gs/obevo/util/VisibleForTesting.java</exclude>

                                <!-- Excluding CATO files -->
                                <exclude>**/src/test/resources/csv-file.txt</exclude>
                                <exclude>**/src/test/resources/testdata1.txt</exclude>
                                <exclude>**/src/test/resources/testdata2.txt</exclude>
                                <exclude>**/src/test/resources/testdata3.txt</exclude>
                                <exclude>**/src/test/resources/testdb.ddl</exclude>
                            </excludes>
                            <strictCheck>true</strictCheck>
                            <skipExistingHeaders>false</skipExistingHeaders>
                        </configuration>
                        <executions>
                            <execution>
                                <id>apply-license</id>
                                <phase>validate</phase>
                                <goals>
                                    <goal>format</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>api-compatibility-check</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>com.github.siom79.japicmp</groupId>
                        <artifactId>japicmp-maven-plugin</artifactId>
                        <version>0.11.0</version>
                        <configuration>
                            <parameter>
                                <onlyBinaryIncompatible>true</onlyBinaryIncompatible>
                                <!--<breakBuildOnBinaryIncompatibleModifications>true</breakBuildOnBinaryIncompatibleModifications>-->
                                <ignoreMissingOldVersion>true</ignoreMissingOldVersion>
                                <includes>
                                    <include>com.gs.obevo.api</include>
                                    <include>com.gs.obevo.db.api</include>
                                    <include>com.gs.obevo.*.api</include>
                                </includes>
                            </parameter>
                        </configuration>
                        <executions>
                            <execution>
                                <phase>verify</phase>
                                <goals>
                                    <goal>cmp</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
