Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade dbs version for testing #1934

Merged
merged 6 commits into from
Jun 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/tracking-orm-6.build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
# Label used to access the service container
mysql:
# Docker Hub image
image: mysql:8.3.0
image: mysql:8.4.0
env:
MYSQL_ROOT_PASSWORD: hreact
MYSQL_DATABASE: hreact
Expand All @@ -61,7 +61,7 @@ jobs:
- 3306:3306
postgres:
# Docker Hub image
image: postgres:16.1
image: postgres:16.3
env:
POSTGRES_DB: hreact
POSTGRES_USER: hreact
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/tracking-vertx-4.build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
# Label used to access the service container
mysql:
# Docker Hub image
image: mysql:8.3.0
image: mysql:8.4.0
env:
MYSQL_ROOT_PASSWORD: hreact
MYSQL_DATABASE: hreact
Expand All @@ -59,7 +59,7 @@ jobs:
- 3306:3306
postgres:
# Docker Hub image
image: postgres:16.1
image: postgres:16.3
env:
POSTGRES_DB: hreact
POSTGRES_USER: hreact
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ Hibernate Reactive has been tested with:

- Java 11, 17, 20, 21
- PostgreSQL 16
- MySQL 8.3
- MySQL 8
- MariaDB 11
- Db2 11.5
- CockroachDB v23.1
- Db2 11
- CockroachDB v24
- MS SQL Server 2022
- Oracle 23
- [Hibernate ORM][] 6.5.2.Final
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class CockroachDBDatabase extends PostgreSQLDatabase {
* TIP: To reuse the same containers across multiple runs, set `testcontainers.reuse.enable=true` in a file located
* at `$HOME/.testcontainers.properties` (create the file if it does not exist).
*/
public static final CockroachContainer cockroachDb = new CockroachContainer( imageName( "cockroachdb/cockroach", "v23.1.17" ) )
public static final CockroachContainer cockroachDb = new CockroachContainer( imageName( "cockroachdb/cockroach", "v24.1.0" ) )
// Username, password and database are not supported by test container at the moment
// Testcontainers will use a database named 'postgres' and the 'root' user
.withReuse( true );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class MariaDatabase extends MySQLDatabase {
* TIP: To reuse the same containers across multiple runs, set `testcontainers.reuse.enable=true` in a file located
* at `$HOME/.testcontainers.properties` (create the file if it does not exist).
*/
public static final MariaDBContainer<?> maria = new MariaDBContainer<>( imageName( "mariadb", "11.3.2" ) )
public static final MariaDBContainer<?> maria = new MariaDBContainer<>( imageName( "mariadb", "11.4.2" ) )
.withUsername( DatabaseConfiguration.USERNAME )
.withPassword( DatabaseConfiguration.PASSWORD )
.withDatabaseName( DatabaseConfiguration.DB_NAME )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ class MySQLDatabase implements TestableDatabase {
* TIP: To reuse the same containers across multiple runs, set `testcontainers.reuse.enable=true` in a file located
* at `$HOME/.testcontainers.properties` (create the file if it does not exist).
*/
public static final MySQLContainer<?> mysql = new MySQLContainer<>( imageName( "mysql", "8.3.0") )
public static final MySQLContainer<?> mysql = new MySQLContainer<>( imageName( "mysql", "8.4.0") )
.withUsername( DatabaseConfiguration.USERNAME )
.withPassword( DatabaseConfiguration.PASSWORD )
.withDatabaseName( DatabaseConfiguration.DB_NAME )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ class PostgreSQLDatabase implements TestableDatabase {
* TIP: To reuse the same containers across multiple runs, set `testcontainers.reuse.enable=true` in a file located
* at `$HOME/.testcontainers.properties` (create the file if it does not exist).
*/
public static final PostgreSQLContainer<?> postgresql = new PostgreSQLContainer<>( imageName( "postgres", "16.2" ) )
public static final PostgreSQLContainer<?> postgresql = new PostgreSQLContainer<>( imageName( "postgres", "16.3" ) )
.withUsername( DatabaseConfiguration.USERNAME )
.withPassword( DatabaseConfiguration.PASSWORD )
.withDatabaseName( DatabaseConfiguration.DB_NAME )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public abstract class BaseReactiveIT {
public static final boolean USE_DOCKER = Boolean.getBoolean( "docker" );

public static final DockerImageName IMAGE_NAME = DockerImageName
.parse( "docker.io/postgres:16.2" )
.parse( "docker.io/postgres:16.3" )
.asCompatibleSubstituteFor( "postgres" );

public static final String USERNAME = "hreact";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public abstract class BaseReactiveIT {
public static final boolean USE_DOCKER = Boolean.getBoolean( "docker" );

public static final DockerImageName IMAGE_NAME = DockerImageName
.parse( "docker.io/postgres:16.2" )
.parse( "docker.io/postgres:16.3" )
.asCompatibleSubstituteFor( "postgres" );

public static final String USERNAME = "hreact";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public class VertxServer {
// These properties are in DatabaseConfiguration in core
public static final boolean USE_DOCKER = Boolean.getBoolean( "docker" );

public static final String IMAGE_NAME = "postgres:16.2";
public static final String IMAGE_NAME = "postgres:16.3";
public static final String USERNAME = "hreact";
public static final String PASSWORD = "hreact";
public static final String DB_NAME = "hreact";
Expand Down
9 changes: 5 additions & 4 deletions podman.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ required credentials and schema to run the tests:
```
podman run --rm --name HibernateTestingPGSQL \
-e POSTGRES_USER=hreact -e POSTGRES_PASSWORD=hreact -e POSTGRES_DB=hreact \
-p 5432:5432 docker.io/postgres:16.2
-e POSTGRES_INITDB_ARGS="-A password" \
-p 5432:5432 docker.io/postgres:16.3
```

When the database has started, you can run the tests on PostgreSQL with:
Expand Down Expand Up @@ -66,7 +67,7 @@ and schema to run the tests:
```
podman run --rm --name HibernateTestingMariaDB \
-e MYSQL_ROOT_PASSWORD=hreact -e MYSQL_DATABASE=hreact -e MYSQL_USER=hreact -e MYSQL_PASSWORD=hreact \
-p 3306:3306 docker.io/mariadb:11.3.2
-p 3306:3306 docker.io/mariadb:11.4.2
```

When the database has started, you can run the tests on MariaDB with:
Expand All @@ -93,7 +94,7 @@ and schema to run the tests:
```
podman run --rm --name HibernateTestingMySQL \
-e MYSQL_ROOT_PASSWORD=hreact -e MYSQL_DATABASE=hreact -e MYSQL_USER=hreact -e MYSQL_PASSWORD=hreact \
-p 3306:3306 docker.io/mysql:8.3.0
-p 3306:3306 docker.io/mysql:8.4.0
```

When the database has started, you can run the tests on MySQL with:
Expand All @@ -120,7 +121,7 @@ configured to run the tests:
```
podman run --rm --name=HibernateTestingCockroachDB \
--hostname=roachrr1 -p 26257:26257 -p 8080:8080 \
docker.io/cockroachdb/cockroach:v23.1.17 start-single-node --insecure
docker.io/cockroachdb/cockroach:v24.1.0 start-single-node --insecure
```

Some of tests needs temporary tables and because this is an experimental feature in
Expand Down
2 changes: 1 addition & 1 deletion tooling/jbang/CockroachDBReactiveTest.java.qute
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public class {baseName} {
}

@ClassRule
public final static CockroachContainer database = new CockroachContainer( imageName( "cockroachdb", "cockroach", "v23.1.17" ) );
public final static CockroachContainer database = new CockroachContainer( imageName( "cockroachdb", "cockroach", "v24.1.0" ) );

private Mutiny.SessionFactory sessionFactory;

Expand Down
2 changes: 1 addition & 1 deletion tooling/jbang/Example.java
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
* <pre>
* podman run --rm --name HibernateTestingPGSQL \
* -e POSTGRES_USER=hreact -e POSTGRES_PASSWORD=hreact -e POSTGRES_DB=hreact \
* -p 5432:5432 postgres:16.2
* -p 5432:5432 postgres:16.3
* </pre>
* </dd>
* <dt>3. Run the example with JBang</dt>
Expand Down
2 changes: 1 addition & 1 deletion tooling/jbang/MariaDBReactiveTest.java.qute
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public class {baseName} {
}

@ClassRule
public final static MariaDBContainer<?> database = new MariaDBContainer<>( imageName( "docker.io", "mariadb", "11.3.2" ) );
public final static MariaDBContainer<?> database = new MariaDBContainer<>( imageName( "docker.io", "mariadb", "11.4.2" ) );

private Mutiny.SessionFactory sessionFactory;

Expand Down
2 changes: 1 addition & 1 deletion tooling/jbang/MySQLReactiveTest.java.qute
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ public class {baseName} {
}

@ClassRule
public final static MySQLContainer<?> database = new MySQLContainer<>( imageName( "docker.io", "mysql", "8.3.0" ) );
public final static MySQLContainer<?> database = new MySQLContainer<>( imageName( "docker.io", "mysql", "8.4.0" ) );

private Mutiny.SessionFactory sessionFactory;

Expand Down
2 changes: 1 addition & 1 deletion tooling/jbang/PostgreSQLReactiveTest.java.qute
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public class {baseName} {
}

@ClassRule
public final static PostgreSQLContainer database = new PostgreSQLContainer( imageName( "docker.io", "postgres", "16.2" ) );
public final static PostgreSQLContainer database = new PostgreSQLContainer( imageName( "docker.io", "postgres", "16.3" ) );

private Mutiny.SessionFactory sessionFactory;

Expand Down
8 changes: 4 additions & 4 deletions tooling/jbang/ReactiveTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -228,11 +228,11 @@ public String toString() {
* It's a wrapper around the testcontainers classes.
*/
enum Database {
POSTGRESQL( () -> new PostgreSQLContainer( "postgres:16.2" ) ),
MYSQL( () -> new MySQLContainer( "mysql:8.3.0" ) ),
POSTGRESQL( () -> new PostgreSQLContainer( "postgres:16.3" ) ),
MYSQL( () -> new MySQLContainer( "mysql:8.4.0" ) ),
DB2( () -> new Db2Container( "docker.io/icr.io/db2_community/db2:11.5.9.0" ).acceptLicense() ),
MARIADB( () -> new MariaDBContainer( "mariadb:11.3.2" ) ),
COCKROACHDB( () -> new CockroachContainer( "cockroachdb/cockroach:v23.1.17" ) );
MARIADB( () -> new MariaDBContainer( "mariadb:11.4.2" ) ),
COCKROACHDB( () -> new CockroachContainer( "cockroachdb/cockroach:v24.1.0" ) );

private final Supplier<JdbcDatabaseContainer<?>> containerSupplier;

Expand Down
Loading