2018-07-04 10:39:54 +02:00
|
|
|
<?xml version="1.0"?>
|
2022-11-10 14:29:05 +01:00
|
|
|
<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">
|
2018-07-04 10:39:54 +02:00
|
|
|
<parent>
|
|
|
|
<groupId>io.debezium</groupId>
|
2019-01-23 12:32:49 +01:00
|
|
|
<artifactId>debezium-parent</artifactId>
|
2024-02-13 10:20:04 +01:00
|
|
|
<version>2.6.0-SNAPSHOT</version>
|
2022-11-01 12:16:01 +01:00
|
|
|
<relativePath>../debezium-parent/pom.xml</relativePath>
|
2018-07-04 10:39:54 +02:00
|
|
|
</parent>
|
|
|
|
<modelVersion>4.0.0</modelVersion>
|
|
|
|
<artifactId>debezium-connector-sqlserver</artifactId>
|
|
|
|
<name>Debezium Connector for MS SQL Server</name>
|
|
|
|
<packaging>jar</packaging>
|
|
|
|
<properties>
|
|
|
|
<!--
|
|
|
|
Specify the properties that will be used for setting up the integration tests' Docker container.
|
|
|
|
Note that the `dockerhost.ip` property is computed from the IP address of DOCKER_HOST, which will
|
|
|
|
work on all platforms. We'll set some of these as system properties during integration testing.
|
|
|
|
-->
|
|
|
|
<sqlserver.port>1433</sqlserver.port>
|
|
|
|
<sqlserver.user>sa</sqlserver.user>
|
|
|
|
<sqlserver.password>Password!</sqlserver.password>
|
2018-07-17 12:51:56 +02:00
|
|
|
<sqlserver.dbname>testDB</sqlserver.dbname>
|
2022-11-29 13:18:18 +01:00
|
|
|
<docker.db>mcr.microsoft.com/mssql/server:2019-latest</docker.db>
|
|
|
|
<docker.filter>${docker.db}</docker.filter>
|
2018-07-04 10:39:54 +02:00
|
|
|
<docker.skip>false</docker.skip>
|
|
|
|
<docker.showLogs>true</docker.showLogs>
|
2022-11-01 12:25:05 +01:00
|
|
|
<!-- Apicurion container properties -->
|
|
|
|
<apicurio.port>8080</apicurio.port>
|
|
|
|
<apicurio.init.timeout>60000</apicurio.init.timeout> <!-- 60 seconds -->
|
2018-07-04 10:39:54 +02:00
|
|
|
</properties>
|
|
|
|
|
|
|
|
<dependencies>
|
|
|
|
<dependency>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-core</artifactId>
|
|
|
|
</dependency>
|
2022-06-14 21:49:56 +02:00
|
|
|
<dependency>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-storage-kafka</artifactId>
|
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-storage-file</artifactId>
|
|
|
|
</dependency>
|
2018-07-04 10:39:54 +02:00
|
|
|
<dependency>
|
|
|
|
<groupId>com.microsoft.sqlserver</groupId>
|
|
|
|
<artifactId>mssql-jdbc</artifactId>
|
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>org.apache.kafka</groupId>
|
|
|
|
<artifactId>connect-api</artifactId>
|
2019-02-14 12:17:29 +01:00
|
|
|
<scope>provided</scope>
|
2018-07-04 10:39:54 +02:00
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>org.slf4j</groupId>
|
|
|
|
<artifactId>slf4j-api</artifactId>
|
2019-02-14 12:17:29 +01:00
|
|
|
<scope>provided</scope>
|
2018-07-04 10:39:54 +02:00
|
|
|
</dependency>
|
|
|
|
|
|
|
|
<!-- Testing -->
|
|
|
|
<dependency>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-embedded</artifactId>
|
|
|
|
<type>test-jar</type>
|
|
|
|
<scope>test</scope>
|
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-core</artifactId>
|
|
|
|
<type>test-jar</type>
|
|
|
|
<scope>test</scope>
|
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-embedded</artifactId>
|
|
|
|
<scope>test</scope>
|
|
|
|
</dependency>
|
|
|
|
<dependency>
|
2022-01-11 09:09:09 +01:00
|
|
|
<groupId>ch.qos.logback</groupId>
|
|
|
|
<artifactId>logback-classic</artifactId>
|
2019-02-14 12:17:29 +01:00
|
|
|
<scope>test</scope>
|
2018-07-04 10:39:54 +02:00
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>junit</groupId>
|
|
|
|
<artifactId>junit</artifactId>
|
2019-02-14 12:17:29 +01:00
|
|
|
<scope>test</scope>
|
2019-10-08 06:18:16 +02:00
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>org.awaitility</groupId>
|
|
|
|
<artifactId>awaitility</artifactId>
|
|
|
|
<scope>test</scope>
|
2018-07-04 10:39:54 +02:00
|
|
|
</dependency>
|
|
|
|
<dependency>
|
2022-11-01 19:38:11 +01:00
|
|
|
<groupId>org.assertj</groupId>
|
|
|
|
<artifactId>assertj-core</artifactId>
|
2019-02-14 12:17:29 +01:00
|
|
|
<scope>test</scope>
|
2018-07-04 10:39:54 +02:00
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>io.confluent</groupId>
|
|
|
|
<artifactId>kafka-connect-avro-converter</artifactId>
|
2019-02-14 12:17:29 +01:00
|
|
|
<scope>test</scope>
|
2018-07-04 10:39:54 +02:00
|
|
|
</dependency>
|
2022-11-21 16:42:42 +01:00
|
|
|
<dependency>
|
|
|
|
<groupId>io.apicurio</groupId>
|
|
|
|
<artifactId>apicurio-registry-utils-converter</artifactId>
|
|
|
|
<scope>test</scope>
|
2023-07-21 15:19:28 +02:00
|
|
|
<exclusions>
|
|
|
|
<exclusion>
|
|
|
|
<artifactId>slf4j-jboss-logmanager</artifactId>
|
|
|
|
<groupId>org.jboss.slf4j</groupId>
|
|
|
|
</exclusion>
|
|
|
|
</exclusions>
|
2022-11-21 16:42:42 +01:00
|
|
|
</dependency>
|
2023-08-29 19:53:31 +02:00
|
|
|
<dependency>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-testing-testcontainers</artifactId>
|
|
|
|
<scope>test</scope>
|
|
|
|
<exclusions>
|
|
|
|
<exclusion>
|
|
|
|
<groupId>org.junit.platform</groupId>
|
|
|
|
<artifactId>junit-platform-launcher</artifactId>
|
|
|
|
</exclusion>
|
|
|
|
<exclusion>
|
|
|
|
<groupId>org.junit.jupiter</groupId>
|
|
|
|
<artifactId>junit-jupiter</artifactId>
|
|
|
|
</exclusion>
|
|
|
|
</exclusions>
|
|
|
|
</dependency>
|
|
|
|
<dependency>
|
|
|
|
<groupId>io.rest-assured</groupId>
|
|
|
|
<artifactId>rest-assured</artifactId>
|
|
|
|
<scope>test</scope>
|
|
|
|
</dependency>
|
2018-07-04 10:39:54 +02:00
|
|
|
</dependencies>
|
|
|
|
|
|
|
|
<build>
|
|
|
|
<plugins>
|
|
|
|
<plugin>
|
|
|
|
<groupId>io.fabric8</groupId>
|
|
|
|
<artifactId>docker-maven-plugin</artifactId>
|
|
|
|
<configuration>
|
|
|
|
<watchInterval>500</watchInterval>
|
|
|
|
<logDate>default</logDate>
|
|
|
|
<verbose>true</verbose>
|
|
|
|
<images>
|
|
|
|
<image>
|
|
|
|
<!-- A Docker image using the SQL Server -->
|
2022-11-29 13:18:18 +01:00
|
|
|
<name>${docker.db}</name>
|
2018-07-04 10:39:54 +02:00
|
|
|
<run>
|
|
|
|
<namingStrategy>none</namingStrategy>
|
|
|
|
<env>
|
|
|
|
<ACCEPT_EULA>Y</ACCEPT_EULA>
|
|
|
|
<SA_PASSWORD>${sqlserver.password}</SA_PASSWORD>
|
|
|
|
<MSSQL_PID>Standard</MSSQL_PID>
|
2018-08-22 08:51:44 +02:00
|
|
|
<MSSQL_AGENT_ENABLED>true</MSSQL_AGENT_ENABLED>
|
2021-08-17 01:50:56 +02:00
|
|
|
<TZ>Asia/Kathmandu</TZ>
|
2018-07-04 10:39:54 +02:00
|
|
|
</env>
|
2022-07-22 23:22:10 +02:00
|
|
|
<volumes>
|
|
|
|
<bind>
|
|
|
|
<volume>${project.basedir}/src/test/docker/mssql.key:/etc/ssl/debezium/private/mssql.key</volume>
|
|
|
|
<volume>${project.basedir}/src/test/docker/mssql.pem:/etc/ssl/debezium/certs/mssql.pem</volume>
|
|
|
|
<volume>${project.basedir}/src/test/docker/mssql.conf:/var/opt/mssql/mssql.conf</volume>
|
|
|
|
</bind>
|
|
|
|
</volumes>
|
2018-07-04 10:39:54 +02:00
|
|
|
<ports>
|
|
|
|
<port>${sqlserver.port}:1433</port>
|
|
|
|
</ports>
|
|
|
|
<log>
|
|
|
|
<prefix>sqlserver</prefix>
|
|
|
|
<enabled>true</enabled>
|
|
|
|
<color>yellow</color>
|
|
|
|
</log>
|
|
|
|
<wait>
|
2019-11-15 12:43:34 +01:00
|
|
|
<time>60000</time> <!-- 60 seconds max -->
|
2018-07-04 10:39:54 +02:00
|
|
|
<log>SQL Server is now ready for client connections</log>
|
|
|
|
</wait>
|
|
|
|
</run>
|
2022-09-27 14:04:00 +02:00
|
|
|
<external>
|
|
|
|
<type>properties</type>
|
|
|
|
<mode>override</mode>
|
|
|
|
</external>
|
2018-07-04 10:39:54 +02:00
|
|
|
</image>
|
2022-11-01 12:25:05 +01:00
|
|
|
<image>
|
|
|
|
<name>apicurio/apicurio-registry-mem:${version.apicurio}</name>
|
|
|
|
<run>
|
|
|
|
<namingStrategy>none</namingStrategy>
|
|
|
|
<ports>
|
|
|
|
<port>${apicurio.port}:8080</port>
|
|
|
|
</ports>
|
|
|
|
<log>
|
|
|
|
<prefix>apicurio</prefix>
|
|
|
|
<enabled>true</enabled>
|
|
|
|
<color>blue</color>
|
|
|
|
</log>
|
|
|
|
<wait>
|
|
|
|
<log>.*apicurio-registry-app.*started in.*</log>
|
|
|
|
<time>${apicurio.init.timeout}</time>
|
|
|
|
</wait>
|
|
|
|
</run>
|
|
|
|
</image>
|
2018-07-04 10:39:54 +02:00
|
|
|
</images>
|
|
|
|
</configuration>
|
|
|
|
<!--
|
|
|
|
Connect this plugin to the maven lifecycle around the integration-test phase:
|
|
|
|
start the container in pre-integration-test and stop it in post-integration-test.
|
|
|
|
-->
|
|
|
|
<executions>
|
|
|
|
<execution>
|
|
|
|
<id>start</id>
|
|
|
|
<phase>pre-integration-test</phase>
|
|
|
|
<goals>
|
|
|
|
<goal>start</goal>
|
|
|
|
</goals>
|
|
|
|
</execution>
|
|
|
|
<execution>
|
|
|
|
<id>stop</id>
|
|
|
|
<phase>post-integration-test</phase>
|
|
|
|
<goals>
|
|
|
|
<goal>stop</goal>
|
|
|
|
</goals>
|
|
|
|
</execution>
|
|
|
|
</executions>
|
|
|
|
</plugin>
|
|
|
|
<!--
|
|
|
|
Unlike surefire, the failsafe plugin ensures 'post-integration-test' phase always runs, even
|
|
|
|
when there are failed integration tests. We rely upon this to always shut down the Docker container
|
|
|
|
after the integration tests (defined as '*IT.java') are run.
|
|
|
|
-->
|
|
|
|
<plugin>
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
<artifactId>maven-failsafe-plugin</artifactId>
|
|
|
|
<executions>
|
|
|
|
<execution>
|
|
|
|
<id>integration-test</id>
|
|
|
|
<goals>
|
|
|
|
<goal>integration-test</goal>
|
|
|
|
</goals>
|
|
|
|
</execution>
|
|
|
|
<execution>
|
|
|
|
<id>verify</id>
|
|
|
|
<goals>
|
|
|
|
<goal>verify</goal>
|
|
|
|
</goals>
|
|
|
|
</execution>
|
|
|
|
</executions>
|
|
|
|
<configuration>
|
|
|
|
<skipTests>${skipITs}</skipTests>
|
|
|
|
<enableAssertions>true</enableAssertions>
|
|
|
|
<systemPropertyVariables>
|
|
|
|
<!-- Make these available to the tests via system properties -->
|
|
|
|
<database.hostname>${docker.host.address}</database.hostname>
|
|
|
|
<database.port>${sqlserver.port}</database.port>
|
|
|
|
<database.user>${sqlserver.user}</database.user>
|
|
|
|
<database.password>${sqlserver.password}</database.password>
|
2022-07-22 23:22:10 +02:00
|
|
|
<database.ssl.truststore>${project.basedir}/src/test/resources/ssl</database.ssl.truststore>
|
|
|
|
<database.ssl.truststore.password>debezium</database.ssl.truststore.password>
|
|
|
|
<database.trustServerCertificate>true</database.trustServerCertificate>
|
2018-07-04 10:39:54 +02:00
|
|
|
<skipLongRunningTests>${skipLongRunningTests}</skipLongRunningTests>
|
|
|
|
</systemPropertyVariables>
|
2022-12-05 13:00:07 +01:00
|
|
|
<runOrder>${runOrder}</runOrder>
|
2018-07-04 10:39:54 +02:00
|
|
|
</configuration>
|
|
|
|
</plugin>
|
2022-01-04 08:47:16 +01:00
|
|
|
<plugin>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-schema-generator</artifactId>
|
|
|
|
<version>${project.version}</version>
|
|
|
|
<executions>
|
|
|
|
<execution>
|
|
|
|
<id>generate-connector-metadata</id>
|
|
|
|
<goals>
|
2022-01-06 15:17:02 +01:00
|
|
|
<goal>generate-api-spec</goal>
|
2022-01-04 08:47:16 +01:00
|
|
|
</goals>
|
|
|
|
<phase>prepare-package</phase>
|
2023-08-29 19:53:31 +02:00
|
|
|
<configuration>
|
|
|
|
<outputDirectory>${project.build.outputDirectory}/META-INF/resources/</outputDirectory>
|
|
|
|
</configuration>
|
2022-01-04 08:47:16 +01:00
|
|
|
</execution>
|
|
|
|
</executions>
|
|
|
|
</plugin>
|
2018-07-04 10:39:54 +02:00
|
|
|
</plugins>
|
|
|
|
<resources>
|
|
|
|
<!-- Apply the properties set in the POM to the resource files -->
|
|
|
|
<resource>
|
|
|
|
<filtering>true</filtering>
|
|
|
|
<directory>src/main/resources</directory>
|
|
|
|
<includes>
|
|
|
|
<include>*</include>
|
|
|
|
<include>**/*</include>
|
|
|
|
</includes>
|
|
|
|
</resource>
|
|
|
|
</resources>
|
|
|
|
<testResources>
|
|
|
|
<testResource>
|
|
|
|
<directory>src/test/resources</directory>
|
|
|
|
<filtering>true</filtering>
|
|
|
|
<includes>
|
|
|
|
<include>*</include>
|
|
|
|
<include>**/*</include>
|
|
|
|
</includes>
|
|
|
|
</testResource>
|
|
|
|
</testResources>
|
|
|
|
</build>
|
|
|
|
<!--
|
|
|
|
Define several useful profiles
|
|
|
|
-->
|
|
|
|
<profiles>
|
|
|
|
<profile>
|
|
|
|
<id>assembly</id>
|
|
|
|
<activation>
|
|
|
|
<activeByDefault>false</activeByDefault>
|
|
|
|
</activation>
|
|
|
|
<build>
|
|
|
|
<plugins>
|
|
|
|
<plugin>
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
<artifactId>maven-assembly-plugin</artifactId>
|
2019-09-23 19:01:44 +02:00
|
|
|
<version>${version.assembly.plugin}</version>
|
2018-07-04 10:39:54 +02:00
|
|
|
<dependencies>
|
|
|
|
<dependency>
|
|
|
|
<groupId>io.debezium</groupId>
|
|
|
|
<artifactId>debezium-assembly-descriptors</artifactId>
|
|
|
|
<version>${project.version}</version>
|
|
|
|
</dependency>
|
|
|
|
</dependencies>
|
|
|
|
<executions>
|
|
|
|
<execution>
|
|
|
|
<id>default</id>
|
|
|
|
<phase>package</phase>
|
|
|
|
<goals>
|
|
|
|
<goal>single</goal>
|
|
|
|
</goals>
|
|
|
|
<configuration>
|
|
|
|
<finalName>${project.artifactId}-${project.version}</finalName>
|
|
|
|
<attach>true</attach> <!-- we want attach & deploy these to Maven -->
|
|
|
|
<descriptorRefs>
|
2019-05-30 09:15:27 +02:00
|
|
|
<descriptorRef>${assembly.descriptor}</descriptorRef>
|
2018-07-04 10:39:54 +02:00
|
|
|
</descriptorRefs>
|
2020-02-07 08:26:47 +01:00
|
|
|
<tarLongFileMode>posix</tarLongFileMode>
|
2018-07-04 10:39:54 +02:00
|
|
|
</configuration>
|
|
|
|
</execution>
|
|
|
|
</executions>
|
|
|
|
</plugin>
|
2023-08-29 19:53:31 +02:00
|
|
|
<plugin>
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
<artifactId>maven-failsafe-plugin</artifactId>
|
|
|
|
<version>${version.failsafe.plugin}</version>
|
|
|
|
<configuration>
|
|
|
|
<systemPropertyVariables>
|
|
|
|
<isAssemblyProfileActive>true</isAssemblyProfileActive>
|
|
|
|
</systemPropertyVariables>
|
|
|
|
</configuration>
|
|
|
|
</plugin>
|
2018-07-04 10:39:54 +02:00
|
|
|
</plugins>
|
|
|
|
</build>
|
|
|
|
</profile>
|
2021-04-21 12:32:40 +02:00
|
|
|
<profile>
|
|
|
|
<id>quick</id>
|
2021-04-26 12:56:34 +02:00
|
|
|
<activation>
|
|
|
|
<activeByDefault>false</activeByDefault>
|
|
|
|
<property>
|
|
|
|
<name>quick</name>
|
|
|
|
</property>
|
|
|
|
</activation>
|
2021-04-21 12:32:40 +02:00
|
|
|
<properties>
|
|
|
|
<skipITs>true</skipITs>
|
|
|
|
<docker.skip>true</docker.skip>
|
|
|
|
</properties>
|
|
|
|
</profile>
|
2018-07-04 10:39:54 +02:00
|
|
|
<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
|
|
Do not perform any Docker-related functionality
|
|
|
|
To use, specify "-DskipITs" on the Maven command line.
|
|
|
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
|
|
|
|
<profile>
|
|
|
|
<id>skip-integration-tests</id>
|
|
|
|
<activation>
|
|
|
|
<activeByDefault>false</activeByDefault>
|
|
|
|
<property>
|
|
|
|
<name>skipITs</name>
|
|
|
|
</property>
|
|
|
|
</activation>
|
|
|
|
<properties>
|
|
|
|
<docker.skip>true</docker.skip>
|
|
|
|
</properties>
|
|
|
|
</profile>
|
2022-11-01 12:25:05 +01:00
|
|
|
<profile>
|
|
|
|
<id>apicurio</id>
|
|
|
|
<activation>
|
|
|
|
<activeByDefault>false</activeByDefault>
|
|
|
|
<property>
|
|
|
|
<name>apicurio</name>
|
|
|
|
</property>
|
|
|
|
</activation>
|
2022-11-03 13:02:49 +01:00
|
|
|
<build>
|
|
|
|
<plugins>
|
|
|
|
<plugin>
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
<artifactId>maven-failsafe-plugin</artifactId>
|
|
|
|
<configuration>
|
|
|
|
<systemPropertyVariables>
|
|
|
|
<use.apicurio>true</use.apicurio>
|
|
|
|
</systemPropertyVariables>
|
|
|
|
</configuration>
|
|
|
|
</plugin>
|
|
|
|
</plugins>
|
|
|
|
</build>
|
2022-11-01 12:25:05 +01:00
|
|
|
<properties>
|
2022-11-29 13:18:18 +01:00
|
|
|
<docker.filter>${docker.db},apicurio/apicurio-registry-mem:${version.apicurio}</docker.filter>
|
2022-11-01 12:25:05 +01:00
|
|
|
</properties>
|
|
|
|
</profile>
|
2018-07-04 10:39:54 +02:00
|
|
|
</profiles>
|
|
|
|
</project>
|