This is an automated email from the ASF dual-hosted git repository.
pjfanning pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/pekko-persistence-jdbc.git
The following commit(s) were added to refs/heads/main by this push:
new c6517fdf Run MariaDB tests in their own database and update MySQL
image to 26.7.0 (#626)
c6517fdf is described below
commit c6517fdf83180d084586e61afca6742b659b7e0c
Author: PJ Fanning <[email protected]>
AuthorDate: Thu Sep 17 16:17:30 2026 +0100
Run MariaDB tests in their own database and update MySQL image to 26.7.0
(#626)
Motivation:
The MariaDB test configs still created the journal tables inside the
`mysql` system schema. On MySQL that combination broke with 9.6.0's
SQL-layer foreign key cascades (tables named `event*` in the `mysql`
schema count as system tables and cannot be write-locked alongside
other tables, see #431). MariaDB does not trip it today, but there is
no reason to keep the footgun. The MySQL 26.7.0 image is also available.
Modification:
Point the MariaDB test configs at a `pekko_persistence_jdbc` database
and create it via MARIADB_DATABASE in docker-compose. Open that
database in the mysql/mariadb cli helper scripts. Bump the MySQL
image to 26.7.0.
Result:
No test tables live in the `mysql` system schema on either server,
and CI tests against the current MySQL release.
Tests:
- sbt ++2.13 "integration/testOnly
org.apache.pekko.persistence.jdbc.integration.MariaDB*" - 190 passed
- sbt ++2.13 "integration/testOnly
org.apache.pekko.persistence.jdbc.integration.MySQL*" against mysql:26.7.0 -
264 passed, 2 timed out (MySQLScalaCurrentEventsByTagTest,
MySQLScalaJdbcDurableStateStoreQueryExplicitSelectSharedTest); the same timeout
occurs against 9.7.2 on the same slow local VM, so CI is the reference for those
- migratorIntegration MySQL suite not run locally - left to CI
References:
Refs #431
---
core/src/test/resources/mariadb-application.conf | 2 +-
core/src/test/resources/mariadb-shared-db-application.conf | 2 +-
scripts/docker-compose.yml | 3 ++-
scripts/mariadb-cli.sh | 2 +-
scripts/mysql-cli.sh | 2 +-
5 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/core/src/test/resources/mariadb-application.conf
b/core/src/test/resources/mariadb-application.conf
index f6305ce9..905ab2c5 100644
--- a/core/src/test/resources/mariadb-application.conf
+++ b/core/src/test/resources/mariadb-application.conf
@@ -58,7 +58,7 @@ slick {
host = ${docker.host}
host = ${?DB_HOST}
# Be careful with the DB port! Default is 3306.
- url =
"jdbc:mariadb://"${slick.db.host}":3307/mysql?cachePrepStmts=true&cacheCallableStmts=true&cacheServerConfiguration=true&useLocalSessionState=true&elideSetAutoCommits=true&alwaysSendSetIsolation=false&enableQueryTimeouts=false&connectionAttributes=none&verifyServerCertificate=false&useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&useLegacyDatetimeCode=false&serverTimezone=UTC&rewriteBatchedStatements=true"
+ url =
"jdbc:mariadb://"${slick.db.host}":3307/pekko_persistence_jdbc?cachePrepStmts=true&cacheCallableStmts=true&cacheServerConfiguration=true&useLocalSessionState=true&elideSetAutoCommits=true&alwaysSendSetIsolation=false&enableQueryTimeouts=false&connectionAttributes=none&verifyServerCertificate=false&useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&useLegacyDatetimeCode=false&serverTimezone=UTC&rewriteBatchedStatements=true"
user = "root"
password = "root"
driver = "org.mariadb.jdbc.Driver"
diff --git a/core/src/test/resources/mariadb-shared-db-application.conf
b/core/src/test/resources/mariadb-shared-db-application.conf
index e9a7cfb0..4fd2a0fb 100644
--- a/core/src/test/resources/mariadb-shared-db-application.conf
+++ b/core/src/test/resources/mariadb-shared-db-application.conf
@@ -40,7 +40,7 @@ pekko-persistence-jdbc {
host = ${docker.host}
host = ${?DB_HOST}
# Be careful with the DB port! Default is 3306.
- url =
"jdbc:mariadb://"${pekko-persistence-jdbc.shared-databases.slick.db.host}":3307/mysql?cachePrepStmts=true&cacheCallableStmts=true&cacheServerConfiguration=true&useLocalSessionState=true&elideSetAutoCommits=true&alwaysSendSetIsolation=false&enableQueryTimeouts=false&connectionAttributes=none&verifyServerCertificate=false&useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&useLegacyDatetimeCode=false&serverTimezone=UTC&rewriteBatchedStatements=true"
+ url =
"jdbc:mariadb://"${pekko-persistence-jdbc.shared-databases.slick.db.host}":3307/pekko_persistence_jdbc?cachePrepStmts=true&cacheCallableStmts=true&cacheServerConfiguration=true&useLocalSessionState=true&elideSetAutoCommits=true&alwaysSendSetIsolation=false&enableQueryTimeouts=false&connectionAttributes=none&verifyServerCertificate=false&useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&useLegacyDatetimeCode=false&serverTimezone=UTC&rewriteBatchedStatements=true"
user = "root"
password = "root"
driver = "org.mariadb.jdbc.Driver"
diff --git a/scripts/docker-compose.yml b/scripts/docker-compose.yml
index 2bc74aa4..ea7e6ece 100644
--- a/scripts/docker-compose.yml
+++ b/scripts/docker-compose.yml
@@ -14,7 +14,7 @@ services:
- "5432:5432" # credentials (docker:docker)
mysql:
- image: mysql:9.7.2
+ image: mysql:26.7.0
container_name: mysql-test
environment:
- "TZ=Europe/Amsterdam"
@@ -29,6 +29,7 @@ services:
environment:
- "TZ=Europe/Amsterdam"
- "MARIADB_ROOT_PASSWORD=root"
+ - "MARIADB_DATABASE=pekko_persistence_jdbc"
ports:
- "3307:3306" # credentials (root:root)
diff --git a/scripts/mariadb-cli.sh b/scripts/mariadb-cli.sh
index a291e62a..0df84c9b 100755
--- a/scripts/mariadb-cli.sh
+++ b/scripts/mariadb-cli.sh
@@ -17,4 +17,4 @@
echo "================== Help for mariadb cli ========================="
echo "================================================================="
-docker exec -it mariadb-test mariadb --user=root --password=root
+docker exec -it mariadb-test mariadb --user=root --password=root
pekko_persistence_jdbc
diff --git a/scripts/mysql-cli.sh b/scripts/mysql-cli.sh
index 22e4f2a2..cd46f330 100755
--- a/scripts/mysql-cli.sh
+++ b/scripts/mysql-cli.sh
@@ -1,4 +1,4 @@
#!/bin/bash
echo "================== Help for mysql cli ========================="
echo "================================================================="
-docker exec -it mysql-test mysql --user=root --password=root mysql
+docker exec -it mysql-test mysql --user=root --password=root
pekko_persistence_jdbc
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]