Refine contribution #4187

Add resource hints for all supported databases
This commit is contained in:
Mahmoud Ben Hassine
2022-09-12 07:41:14 +02:00
parent 2f8668d1f8
commit 06c2dc3a01

View File

@@ -26,6 +26,7 @@ import org.springframework.core.DecoratingProxy;
* {@link RuntimeHintsRegistrar} for Spring Batch core module.
*
* @author Glenn Renfro
* @author Mahmoud Ben Hassine
* @since 5.0
*/
public class CoreRuntimeHints implements RuntimeHintsRegistrar {
@@ -34,6 +35,16 @@ public class CoreRuntimeHints implements RuntimeHintsRegistrar {
public void registerHints(RuntimeHints hints, ClassLoader classLoader) {
hints.resources().registerPattern("org/springframework/batch/core/schema-h2.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-derby.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-hsqldb.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-sqlite.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-db2.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-hana.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-mysql.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-oracle.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-postgresql.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-sqlserver.sql");
hints.resources().registerPattern("org/springframework/batch/core/schema-sybase.sql");
hints.proxies()
.registerJdkProxy(builder -> builder