diff --git a/Jenkinsfile b/Jenkinsfile index 6f667217f6..92c2bd9f87 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -41,7 +41,6 @@ stage('Configure') { // new BuildEnvironment( dbName: 'hana_cloud', dbLockableResource: 'hana-cloud', dbLockResourceAsHost: true ), new BuildEnvironment( node: 's390x' ), new BuildEnvironment( dbName: 'tidb', node: 'tidb', - additionalOptions: '-DdbHost=localhost:4000', notificationRecipients: 'tidb_hibernate@pingcap.com' ), new BuildEnvironment( testJdkVersion: '17' ), // We want to enable preview features when testing newer builds of OpenJDK: diff --git a/README.adoc b/README.adoc index 1e46f441ab..d5d5922f5d 100644 --- a/README.adoc +++ b/README.adoc @@ -202,6 +202,10 @@ The following table illustrates a list of commands for various databases that ca |CockroachDB |`./docker_db.sh cockroachdb` |`./gradlew test -Pdb=cockroachdb` + +|TiDB +|`./docker_db.sh tidb` +|`./gradlew test -Pdb=tidb` |=== To stop a container started by `docker`, use the command diff --git a/docker_db.sh b/docker_db.sh index b984eace9d..fb901a8937 100755 --- a/docker_db.sh +++ b/docker_db.sh @@ -839,6 +839,7 @@ tidb_5_1() { echo "Waiting for TiDB to start..." sleep 3 done + $CONTAINER_CLI run --link tidb:tidb -it --rm docker.io/mysql:8.0.31 mysql -htidb -P4000 -uroot -e "create database hibernate_orm_test; create user 'hibernate_orm_test' identified by 'hibernate_orm_test'; grant all on hibernate_orm_test.* to 'hibernate_orm_test';" if [ "$n" -ge 5 ]; then echo "TiDB failed to start and configure after 15 seconds" else diff --git a/gradle/databases.gradle b/gradle/databases.gradle index eaf9adf60d..2bf93ea1c8 100644 --- a/gradle/databases.gradle +++ b/gradle/databases.gradle @@ -128,7 +128,7 @@ ext { 'jdbc.driver': 'com.mysql.jdbc.Driver', 'jdbc.user' : 'hibernate_orm_test', 'jdbc.pass' : 'hibernate_orm_test', - 'jdbc.url' : 'jdbc:mysql://' + dbHost + '/hibernate_orm_test', + 'jdbc.url' : 'jdbc:mysql://' + dbHost + ':4000/hibernate_orm_test', 'connection.init_sql' : '' ], oracle : [