From 61c9a1540fe639e5905e2640e3fa8ce2123a76e8 Mon Sep 17 00:00:00 2001 From: Andy Wilkinson Date: Tue, 1 Nov 2022 11:41:48 +0000 Subject: [PATCH] Start building against Spring Batch 5.0.0-RC2 snapshots See gh-32935 --- .../batch/BatchDataSourceScriptDatabaseInitializer.java | 2 -- .../batch/BatchDataSourceScriptDatabaseInitializerTests.java | 5 +++-- spring-boot-project/spring-boot-dependencies/build.gradle | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceScriptDatabaseInitializer.java b/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceScriptDatabaseInitializer.java index ec67e1ba7e..c45b5e9a0f 100644 --- a/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceScriptDatabaseInitializer.java +++ b/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceScriptDatabaseInitializer.java @@ -20,7 +20,6 @@ import java.util.List; import javax.sql.DataSource; -import org.springframework.boot.jdbc.DatabaseDriver; import org.springframework.boot.jdbc.init.DataSourceScriptDatabaseInitializer; import org.springframework.boot.jdbc.init.PlatformPlaceholderDatabaseDriverResolver; import org.springframework.boot.sql.init.DatabaseInitializationSettings; @@ -78,7 +77,6 @@ public class BatchDataSourceScriptDatabaseInitializer extends DataSourceScriptDa private static List resolveSchemaLocations(DataSource dataSource, BatchProperties.Jdbc properties) { PlatformPlaceholderDatabaseDriverResolver platformResolver = new PlatformPlaceholderDatabaseDriverResolver(); - platformResolver = platformResolver.withDriverPlatform(DatabaseDriver.MARIADB, "mysql"); if (StringUtils.hasText(properties.getPlatform())) { return platformResolver.resolveAll(properties.getPlatform(), properties.getSchema()); } diff --git a/spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceScriptDatabaseInitializerTests.java b/spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceScriptDatabaseInitializerTests.java index e9ad03ec02..ed47fe4e29 100644 --- a/spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceScriptDatabaseInitializerTests.java +++ b/spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceScriptDatabaseInitializerTests.java @@ -88,8 +88,9 @@ class BatchDataSourceScriptDatabaseInitializerTests { .map((resource) -> resource.getFilename()).filter((resourceName) -> !resourceName.contains("-drop-")) .toList(); assertThat(schemaNames).containsExactlyInAnyOrder("schema-derby.sql", "schema-sqlserver.sql", - "schema-mysql.sql", "schema-sqlite.sql", "schema-postgresql.sql", "schema-hana.sql", - "schema-oracle.sql", "schema-db2.sql", "schema-hsqldb.sql", "schema-sybase.sql", "schema-h2.sql"); + "schema-mariadb.sql", "schema-mysql.sql", "schema-sqlite.sql", "schema-postgresql.sql", + "schema-hana.sql", "schema-oracle.sql", "schema-db2.sql", "schema-hsqldb.sql", "schema-sybase.sql", + "schema-h2.sql"); } } diff --git a/spring-boot-project/spring-boot-dependencies/build.gradle b/spring-boot-project/spring-boot-dependencies/build.gradle index bde960d9f2..f83f93fcd0 100644 --- a/spring-boot-project/spring-boot-dependencies/build.gradle +++ b/spring-boot-project/spring-boot-dependencies/build.gradle @@ -1421,7 +1421,7 @@ bom { ] } } - library("Spring Batch", "5.0.0-RC1") { + library("Spring Batch", "5.0.0-SNAPSHOT") { group("org.springframework.batch") { imports = [ "spring-batch-bom"