<?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.github.jinahya</groupId>
    <artifactId>jinahya-parent</artifactId>
    <version>0.8.6</version>
  </parent>

  <artifactId>database-metadata-bind</artifactId>
  <version>3.2.0</version>
  <packaging>jar</packaging>

  <name>${project.artifactId}</name>
  <description>bindings for java.sql.DatabaseMetaData</description>
  <url>https://github.com/jinahya/$project.artifactId}</url>
  <inceptionYear>2011</inceptionYear>
  <organization>
    <name>Jinahya, Inc.</name>
    <url>https://jinahya.com</url>
  </organization>

  <scm>
    <connection>scm:git:git@github.com:jinahya/${project.artifactId}.git</connection>
    <developerConnection>scm:git:git@github.com:jinahya/${project.artifactId}.git</developerConnection>
    <url>https://github.com:jinahya/${project.artifactId}</url>
    <tag>3.2.0</tag>
  </scm>
  <issueManagement>
    <system>GitHub Issues</system>
    <url>https://github.com/jinahya/${project.artifactId}/issues</url>
  </issueManagement>
  <ciManagement>
    <system>Travis CI</system>
    <url>https://travis-ci.org/jinahya/${project.artifactId}</url>
  </ciManagement>

  <properties>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>${maven.compiler.source}</maven.compiler.target>
    <maven.compiler.testSource>${maven.compiler.source}</maven.compiler.testSource>
    <maven.compiler.testTarget>${maven.compiler.testSource}</maven.compiler.testTarget>
    <version.animal-sniffer>1.20</version.animal-sniffer>
    <version.com.sun.xml.bind>${version.jakarta.xml.bind-api}</version.com.sun.xml.bind>
    <version.jakarta.validation-api>2.0.2</version.jakarta.validation-api>
    <version.jakarta.xml.bind-api>2.3.3</version.jakarta.xml.bind-api>
    <version.mariadb-java-client>2.7.2</version.mariadb-java-client>
    <version.maven-failsafe>${version.maven-surefire}</version.maven-failsafe>
    <version.maven-surefire>3.0.0-M4</version.maven-surefire>
    <version.mysql-connector-java>8.0.23</version.mysql-connector-java>
    <version.mssql-jdbc>9.2.1.jre15</version.mssql-jdbc>
    <version.ojdbc6>11.2.0.4</version.ojdbc6>
    <version.ojdbc8>21.1.0.0</version.ojdbc8>
    <version.ojdbc10>19.10.0.0</version.ojdbc10>
    <version.ojdbc11>21.1.0.0</version.ojdbc11>
    <version.org.hibernate.validator>6.2.0.Final</version.org.hibernate.validator>
    <version.org.junit.jupiter>5.8.0-M1</version.org.junit.jupiter>
    <version.org.testcontainers>1.15.3</version.org.testcontainers>
    <version.postgresql>42.2.19.jre7</version.postgresql>
    <version.presto-jdbc>350</version.presto-jdbc>
  </properties>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>com.microsoft.sqlserver</groupId>
        <artifactId>mssql-jdbc</artifactId>
        <version>${version.mssql-jdbc}</version>
      </dependency>
      <dependency>
        <groupId>com.oracle.database.jdbc</groupId>
        <artifactId>ojdbc6</artifactId>
        <version>${version.ojdbc6}</version>
      </dependency>
      <dependency>
        <groupId>com.oracle.database.jdbc</groupId>
        <artifactId>ojdbc8</artifactId>
        <version>${version.ojdbc8}</version>
      </dependency>
      <dependency>
        <groupId>com.oracle.database.jdbc</groupId>
        <artifactId>ojdbc10</artifactId>
        <version>${version.ojdbc10}</version>
      </dependency>
      <dependency>
        <groupId>com.oracle.database.jdbc</groupId>
        <artifactId>ojdbc11</artifactId>
        <version>${version.ojdbc11}</version>
      </dependency>
      <dependency>
        <groupId>io.prestosql</groupId>
        <artifactId>presto-jdbc</artifactId>
        <version>${version.presto-jdbc}</version>
      </dependency>
      <dependency>
        <groupId>mysql</groupId>
        <artifactId>mysql-connector-java</artifactId>
        <version>${version.mysql-connector-java}</version>
      </dependency>
      <dependency>
        <groupId>org.mariadb.jdbc</groupId>
        <artifactId>mariadb-java-client</artifactId>
        <version>${version.mariadb-java-client}</version>
      </dependency>
      <dependency>
        <groupId>org.postgresql</groupId>
        <artifactId>postgresql</artifactId>
        <version>${version.postgresql}</version>
      </dependency>
      <dependency>
        <groupId>org.testcontainers</groupId>
        <artifactId>testcontainers-bom</artifactId>
        <version>${version.org.testcontainers}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>
  <dependencies>
    <dependency>
      <groupId>ch.qos.logback</groupId>
      <artifactId>logback-classic</artifactId>
      <version>1.2.3</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.diffplug.durian</groupId>
      <artifactId>durian</artifactId>
      <version>3.4.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.h2database</groupId>
      <artifactId>h2</artifactId>
      <version>1.4.200</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.launchableinc</groupId>
      <artifactId>cyyoung</artifactId>
      <version>2.0</version>
      <scope>test</scope>
    </dependency>
    <!--    <dependency>-->
    <!--      <groupId>com.sun.xml.bind</groupId>-->
    <!--      <artifactId>jaxb-core</artifactId>-->
    <!--      <version>${version.com.sun.xml.bind}</version>-->
    <!--      <scope>test</scope>-->
    <!--    </dependency>-->
    <dependency>
      <groupId>com.sun.xml.bind</groupId>
      <artifactId>jaxb-impl</artifactId>
      <version>${version.com.sun.xml.bind}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>jakarta.xml.bind</groupId>
      <artifactId>jakarta.xml.bind-api</artifactId>
      <version>2.3.3</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>jakarta.validation</groupId>
      <artifactId>jakarta.validation-api</artifactId>
      <version>${version.jakarta.validation-api}</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.derby</groupId>
      <artifactId>derby</artifactId>
      <version>10.14.2.0</version>
      <!-- https://db.apache.org/derby/derby_downloads.html#For+Java+8+and+Higher -->
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.assertj</groupId>
      <artifactId>assertj-core</artifactId>
      <version>3.19.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.codehaus.mojo</groupId>
      <artifactId>animal-sniffer-annotations</artifactId>
      <version>${version.animal-sniffer}</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.glassfish</groupId>
      <artifactId>jakarta.el</artifactId>
      <version>3.0.3</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.hibernate.validator</groupId>
      <artifactId>hibernate-validator</artifactId>
      <!--      <version>6.1.7.Final</version>-->
      <version>${version.org.hibernate.validator}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.hsqldb</groupId>
      <artifactId>hsqldb</artifactId>
      <version>2.5.2</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-api</artifactId>
      <version>${version.org.junit.jupiter}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-engine</artifactId>
      <version>${version.org.junit.jupiter}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.projectlombok</groupId>
      <artifactId>lombok</artifactId>
      <version>1.18.20</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <version>1.7.25</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>org.xerial</groupId>
      <artifactId>sqlite-jdbc</artifactId>
      <version>3.34.0</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.8.1</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-failsafe-plugin</artifactId>
          <version>${version.maven-failsafe}</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>${version.maven-surefire}</version>
          <configuration>
            <systemPropertyVariables>
              <org.jboss.logging.provider>jdk</org.jboss.logging.provider>
            </systemPropertyVariables>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-jar-plugin</artifactId>
          <version>3.2.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-project-info-reports-plugin</artifactId>
          <version>3.0.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-site-plugin</artifactId>
          <version>3.9.0</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>build-helper-maven-plugin</artifactId>
          <version>3.1.0</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>versions-maven-plugin</artifactId>
          <version>2.8.1</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>sonar-maven-plugin</artifactId>
          <version>3.7.0.1746</version>
        </plugin>
        <plugin>
          <groupId>org.jacoco</groupId>
          <artifactId>jacoco-maven-plugin</artifactId>
          <version>0.8.6</version>
        </plugin>
      </plugins>
    </pluginManagement>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <compilerArgs>
            <arg>-Xlint</arg>
          </compilerArgs>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <version>3.0.0-M3</version>
        <executions>
          <execution>
            <id>enforce</id>
            <configuration>
              <skip>true</skip>
              <rules>
                <dependencyConvergence />
              </rules>
            </configuration>
            <goals>
              <goal>enforce</goal>
            </goals>
          </execution>
          <execution>
            <id>enforce-require-java-version-to-[1.8.0,)</id>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <skip>false</skip>
              <rules>
                <requireJavaVersion>
                  <version>[1.8.0,)</version>
                </requireJavaVersion>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <systemProperties>
            <property>
              <name>derby.stream.error.file</name>
              <value>target/derby.log</value>
            </property>
          </systemProperties>
          <trimStackTrace>false</trimStackTrace>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>animal-sniffer-maven-plugin</artifactId>
        <version>${version.animal-sniffer}</version>
        <executions>
          <execution>
            <id>check-against-java18</id>
            <phase>test</phase>
            <goals>
              <goal>check</goal>
            </goals>
            <configuration>
              <signature>
                <groupId>org.codehaus.mojo.signature</groupId>
                <artifactId>java18</artifactId>
                <version>1.0</version>
              </signature>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>license-maven-plugin</artifactId>
        <version>2.0.0</version>
        <configuration>
          <licenseName>apache_v2</licenseName>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <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>
        </executions>
      </plugin>
    </plugins>
  </build>

  <reporting>
    <plugins>
      <plugin>
        <groupId>com.github.spotbugs</groupId>
        <artifactId>spotbugs-maven-plugin</artifactId>
        <version>3.1.12.2</version>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jxr-plugin</artifactId>
        <version>3.0.0</version>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-checkstyle-plugin</artifactId>
        <version>3.1.1</version>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-pmd-plugin</artifactId>
        <version>3.13.0</version>
      </plugin>
      <plugin>
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <reportSets>
          <reportSet>
            <reports>
              <report>report</report>
            </reports>
          </reportSet>
        </reportSets>
      </plugin>
    </plugins>
  </reporting>

  <profiles>
    <profile>
      <id>memory</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <configuration>
              <forkedProcessExitTimeoutInSeconds>900</forkedProcessExitTimeoutInSeconds>
              <forkedProcessTimeoutInSeconds>0</forkedProcessTimeoutInSeconds>
              <includes>
                <include>MemoryDerbyTest.java</include>
                <include>MemoryH2Test.java</include>
                <include>MemoryHsqlTest.java</include>
                <include>MemorySqliteTest.java</include>
              </includes>
              <systemPropertyVariables>
                <memory>true</memory>
              </systemPropertyVariables>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>failsafe</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <configuration>
              <!--              <skipTests>true</skipTests>-->
            </configuration>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-failsafe-plugin</artifactId>
            <version>${version.maven-failsafe}</version>
            <executions>
              <execution>
                <goals>
                  <goal>integration-test</goal>
                  <goal>verify</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>container-only</id>
      <properties>
        <!--        <skipTests>true</skipTests>-->
        <it.test>ContainerIT</it.test>
      </properties>
      <dependencies>
        <!--        <dependency>-->
        <!--          <groupId>org.testcontainers</groupId>-->
        <!--          <artifactId>testcontainers</artifactId>-->
        <!--          <scope>test</scope>-->
        <!--        </dependency>-->
      </dependencies>
    </profile>
    <profile>
      <id>container-mariadb</id>
      <dependencies>
        <dependency>
          <groupId>org.mariadb.jdbc</groupId>
          <artifactId>mariadb-java-client</artifactId>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>org.testcontainers</groupId>
          <artifactId>mariadb</artifactId>
          <scope>test</scope>
        </dependency>
        <!--        <dependency>-->
        <!--          <groupId>org.testcontainers</groupId>-->
        <!--          <artifactId>testcontainers</artifactId>-->
        <!--          <scope>test</scope>-->
        <!--        </dependency>-->
      </dependencies>
    </profile>
    <profile>
      <id>container-mssqlserver</id>
      <dependencies>
        <dependency>
          <groupId>com.microsoft.sqlserver</groupId>
          <artifactId>mssql-jdbc</artifactId>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>org.testcontainers</groupId>
          <artifactId>mssqlserver</artifactId>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>org.testcontainers</groupId>
          <artifactId>testcontainers</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>container-mysql</id>
      <dependencies>
        <dependency>
          <groupId>mysql</groupId>
          <artifactId>mysql-connector-java</artifactId>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>org.testcontainers</groupId>
          <artifactId>mysql</artifactId>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>org.testcontainers</groupId>
          <artifactId>testcontainers</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>container-postgresql</id>
      <dependencies>
        <dependency>
          <groupId>org.postgresql</groupId>
          <artifactId>postgresql</artifactId>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>org.testcontainers</groupId>
          <artifactId>postgresql</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>container-presto</id>
      <dependencies>
        <dependency>
          <groupId>io.prestosql</groupId>
          <artifactId>presto-jdbc</artifactId>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>org.testcontainers</groupId>
          <artifactId>presto</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>external-mariadb</id>
      <dependencies>
        <dependency>
          <groupId>org.mariadb.jdbc</groupId>
          <artifactId>mariadb-java-client</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>external-mysql</id>
      <dependencies>
        <dependency>
          <groupId>mysql</groupId>
          <artifactId>mysql-connector-java</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>external-oracle-ojdbc6</id>
      <dependencies>
        <dependency>
          <groupId>com.oracle.databse.jdbc</groupId>
          <artifactId>ojdbc6</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>external-oracle-ojdbc8</id>
      <dependencies>
        <dependency>
          <groupId>com.oracle.database.jdbc</groupId>
          <artifactId>ojdbc8</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>external-oracle-ojdbc10</id>
      <dependencies>
        <dependency>
          <groupId>com.oracle.database.jdbc</groupId>
          <artifactId>ojdbc8</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>external-oracle-ojdbc11</id>
      <dependencies>
        <dependency>
          <groupId>com.oracle.database.jdbc</groupId>
          <artifactId>ojdbc11</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>external-postgresql</id>
      <dependencies>
        <dependency>
          <groupId>org.postgresql</groupId>
          <artifactId>postgresql</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>external-sqlserver</id>
      <dependencies>
        <dependency>
          <groupId>com.microsoft.sqlserver</groupId>
          <artifactId>mssql-jdbc</artifactId>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
  </profiles>
</project>
