DBZ-2913 Add mariadb profile and GitHub check for MariaDB

This commit is contained in:
Chris Cranford 2023-10-24 22:03:29 -04:00 committed by Jiri Pechanec
parent cec5b67c5a
commit a7989379c1
2 changed files with 54 additions and 1 deletions

View File

@ -358,6 +358,42 @@ jobs:
-Dmaven.wagon.http.pool=false -Dmaven.wagon.http.pool=false
-Dmaven.wagon.httpconnectionManager.ttlSeconds=120 -Dmaven.wagon.httpconnectionManager.ttlSeconds=120
build_mariadb:
needs: [check_style, file_changes]
if: ${{ needs.file_changes.outputs.common-changed == 'true' || needs.file_changes.outputs.mysql-changed == 'true' || needs.file_changes.outputs.mysql-ddl-parser-changed == 'true' || needs.file_changes.outputs.schema-generator-changed == 'true' }}
name: "MariaDB"
runs-on: ubuntu-latest
steps:
- name: Checkout Action
uses: actions/checkout@v4
- name: Set up Java 17
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 17
- name: Cache Maven Repository
uses: actions/cache@v3
with:
path: ~/.m2/repository
key: maven-debezium-test-build-${{ hashFiles('**/pom.xml') }}
restore-keys: |
maven-debezium-test-build-${{ hashFiles('**/pom.xml') }}
- name: Build Debezium Connector MySQL for MariaDB
# We specifically exclude the assembly profile for now as the MariaDB integration is still
# ongoing for GTID and therefore this simply runs the tests like non-assembly builds but
# utilizes the MariaDB database rather than MySQL at this time. It also gives us a chance
# to see how changes react to MariaDB as they're contributed.
run: >
./mvnw clean install -B -pl debezium-connector-mysql -am -Pmariadb
-Dcheckstyle.skip=true
-Dformat.skip=true
-Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn
-Dmaven.wagon.http.pool=false
-Dmaven.wagon.httpconnectionManager.ttlSeconds=120
build_postgresql: build_postgresql:
needs: [check_style, file_changes] needs: [check_style, file_changes]
if: ${{ needs.file_changes.outputs.common-changed == 'true' || needs.file_changes.outputs.postgresql-changed == 'true' || needs.file_changes.outputs.schema-generator-changed == 'true' }} if: ${{ needs.file_changes.outputs.common-changed == 'true' || needs.file_changes.outputs.postgresql-changed == 'true' || needs.file_changes.outputs.schema-generator-changed == 'true' }}

View File

@ -173,6 +173,11 @@
<apicurio.port>8080</apicurio.port> <apicurio.port>8080</apicurio.port>
<apicurio.init.timeout>60000</apicurio.init.timeout> <!-- 60 seconds --> <apicurio.init.timeout>60000</apicurio.init.timeout> <!-- 60 seconds -->
<!-- <!--
MariaDB specific
-->
<mariadb.server.image.source>mariadb</mariadb.server.image.source>
<version.mariadb.server>11.1.2</version.mariadb.server>
<!--
By default, we should use the docker image maintained by the MySQL team. This property is changed with different profiles. By default, we should use the docker image maintained by the MySQL team. This property is changed with different profiles.
However, we run one container with GTIDs and one without. However, we run one container with GTIDs and one without.
--> -->
@ -871,7 +876,7 @@
<!-- Integration test properties --> <!-- Integration test properties -->
<database.port>${mysql.ssl.port}</database.port> <database.port>${mysql.ssl.port}</database.port>
<database.replica.port>${mysql.ssl.port}</database.replica.port> <database.replica.port>${mysql.ssl.port}</database.replica.port>
<docker.initimage>ln -s /usr/share/zoneinfo/Pacific/Pago_Pago /etc/localtime</docker.initimage> <docker.initimage>rm -f /etc/localtime; ln -s /usr/share/zoneinfo/Pacific/Pago_Pago /etc/localtime</docker.initimage>
</properties> </properties>
</profile> </profile>
<profile> <profile>
@ -899,5 +904,17 @@
<docker.filter>${docker.dbs},apicurio/apicurio-registry-mem:${version.apicurio}</docker.filter> <docker.filter>${docker.dbs},apicurio/apicurio-registry-mem:${version.apicurio}</docker.filter>
</properties> </properties>
</profile> </profile>
<!-- Profile used to toggle MariaDB instead of MySQL -->
<profile>
<id>mariadb</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<properties>
<docker.dbs>debezium/mysql-server-test-database</docker.dbs>
<mysql.server.image.source>${mariadb.server.image.source}</mysql.server.image.source>
<version.mysql.server>${version.mariadb.server}</version.mysql.server>
</properties>
</profile>
</profiles> </profiles>
</project> </project>