<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ Copyright (c) 2011-2026 The original author or authors
  ~
  ~ All rights reserved. This program and the accompanying materials
  ~ are made available under the terms of the Eclipse Public License v1.0
  ~ and Apache License v2.0 which accompanies this distribution.
  ~
  ~      The Eclipse Public License is available at
  ~      http://www.eclipse.org/legal/epl-v10.html
  ~
  ~      The Apache License v2.0 is available at
  ~      http://www.opensource.org/licenses/apache2.0.php
  ~
  ~ You may elect to redistribute this code under either of these licenses.
  -->
<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">

  <parent>
    <groupId>io.vertx</groupId>
    <artifactId>vertx5-parent</artifactId>
    <version>15</version>
  </parent>

  <modelVersion>4.0.0</modelVersion>
  <name>Vertx JDBC Client</name>
  <artifactId>vertx-jdbc-client</artifactId>
  <version>5.2.0</version>

  <scm>
    <connection>scm:git:git@github.com:vert-x3/vertx-jdbc-client.git</connection>
    <developerConnection>scm:git:git@github.com:vert-x3/vertx-jdbc-client.git</developerConnection>
    <url>git@github.com:vert-x3/vertx-jdbc-client.git</url>
  </scm>

  <properties>
    <vertx.surefire.useModulePath>false</vertx.surefire.useModulePath>
    <testcontainers>1.21.4</testcontainers>
  </properties>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>io.vertx</groupId>
        <artifactId>vertx-dependencies</artifactId>
        <version>${project.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <dependencies>

    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-core</artifactId>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-codegen-api</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-codegen-json</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-docgen-api</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-sql-client</artifactId>
    </dependency>

    <dependency>
      <!-- this dependency is aligned with the vert.x core one do avoid dependencies to get another version -->
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <optional>true</optional>
    </dependency>

    <!-- Testing -->
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.13.1</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.hsqldb</groupId>
      <artifactId>hsqldb</artifactId>
      <version>2.7.4</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.h2database</groupId>
      <artifactId>h2</artifactId>
      <version>2.4.240</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.mysql</groupId>
      <artifactId>mysql-connector-j</artifactId>
      <version>9.7.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-sql-client</artifactId>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-unit</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.testcontainers</groupId>
      <artifactId>mssqlserver</artifactId>
      <version>${testcontainers}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.microsoft.sqlserver</groupId>
      <artifactId>mssql-jdbc</artifactId>
      <version>13.4.0.jre11</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.testcontainers</groupId>
      <artifactId>clickhouse</artifactId>
      <version>${testcontainers}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.clickhouse</groupId>
      <artifactId>clickhouse-jdbc</artifactId>
      <version>0.9.8</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.oracle.database.jdbc</groupId>
      <artifactId>ojdbc11</artifactId>
      <version>21.21.0.0</version>
    </dependency>
    <dependency>
      <groupId>org.testcontainers</groupId>
      <artifactId>oracle-free</artifactId>
      <version>${testcontainers}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.testcontainers</groupId>
      <artifactId>postgresql</artifactId>
      <version>${testcontainers}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.postgresql</groupId>
      <artifactId>postgresql</artifactId>
      <version>42.7.13</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.testcontainers</groupId>
      <artifactId>mysql</artifactId>
      <version>${testcontainers}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-sql-client-templates</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.13.0</version>
          <executions>
            <execution>
              <id>default-compile</id>
              <configuration>
                <annotationProcessorPaths>
                  <annotationProcessorPath>
                    <groupId>io.vertx</groupId>
                    <artifactId>vertx-codegen</artifactId>
                    <classifier>processor</classifier>
                  </annotationProcessorPath>
                  <annotationProcessorPath>
                    <groupId>io.vertx</groupId>
                    <artifactId>vertx-docgen-processor</artifactId>
                    <classifier>processor</classifier>
                  </annotationProcessorPath>
                </annotationProcessorPaths>
              </configuration>
            </execution>
            <execution>
              <id>default-testCompile</id>
              <configuration>
                <useModulePath>false</useModulePath>
                <annotationProcessorPaths>
                  <annotationProcessorPath>
                    <groupId>io.vertx</groupId>
                    <artifactId>vertx-codegen</artifactId>
                    <classifier>processor</classifier>
                  </annotationProcessorPath>
                  <annotationProcessorPath>
                    <groupId>io.vertx</groupId>
                    <artifactId>vertx-sql-client-templates</artifactId>
                  </annotationProcessorPath>
                </annotationProcessorPaths>
              </configuration>
            </execution>
          </executions>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <configuration>
            <systemPropertyVariables>
              <!-- Necessary for HSQLDB blob testing -->
              <textdb.allow_full_path>true</textdb.allow_full_path>
            </systemPropertyVariables>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>
    <plugins>
      <plugin>
        <artifactId>maven-assembly-plugin</artifactId>
        <executions>
          <execution>
            <id>package-docs</id>
            <goals>
              <goal>single</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>

  <profiles>
    <profile>
      <id>Java-21</id>
      <activation>
        <jdk>[21,)</jdk>
      </activation>
      <dependencies>
        <dependency>
          <groupId>org.apache.derby</groupId>
          <artifactId>derby</artifactId>
          <version>10.17.1.0</version>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
  </profiles>

</project>
