Skip to content

Commit 1d40fda

Browse files
committed
Improve unsupported properties in SpringDataJPAProcessor
Also improve the Javadoc of sqlLoadScript as multiple files are supported now. (cherry picked from commit bf8e4f2)
1 parent bed47fc commit 1d40fda

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

extensions/hibernate-orm/deployment/src/main/java/io/quarkus/hibernate/orm/deployment/HibernateOrmConfigPersistenceUnit.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,10 @@ public interface HibernateOrmConfigPersistenceUnit {
4747

4848
// @formatter:off
4949
/**
50-
* Path to a file containing the SQL statements to execute when Hibernate ORM starts.
50+
* Paths to files containing the SQL statements to execute when Hibernate ORM starts.
5151
*
52-
* The file is retrieved from the classpath resources,
53-
* so it must be located in the resources directory (e.g. `src/main/resources`).
52+
* The files are retrieved from the classpath resources,
53+
* so they must be located in the resources directory (e.g. `src/main/resources`).
5454
*
5555
* The default value for this setting differs depending on the Quarkus launch mode:
5656
*
@@ -82,7 +82,7 @@ public interface HibernateOrmConfigPersistenceUnit {
8282
* @asciidoclet
8383
*/
8484
// @formatter:on
85-
@ConfigDocDefault("import.sql in DEV, TEST ; no-file otherwise")
85+
@ConfigDocDefault("import.sql in dev and test modes ; no-file otherwise")
8686
Optional<List<@WithConverter(TrimmedStringConverter.class) String>> sqlLoadScript();
8787

8888
/**

extensions/spring-data-jpa/deployment/src/main/java/io/quarkus/spring/data/deployment/SpringDataJPAProcessor.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -206,12 +206,12 @@ private void detectAndLogSpecificSpringPropertiesIfExist() {
206206
case SPRING_DATASOURCE_DATA:
207207
notSupportedProperties = notSupportedProperties + "\t- " + QUARKUS_HIBERNATE_ORM_SQL_LOAD_SCRIPT
208208
+ " could be used to load data instead of " + SPRING_DATASOURCE_DATA
209-
+ " but it does not support either comma separated list of resources or resources with ant-style patterns as "
209+
+ " but it does not support ant-style patterns as "
210210
+ SPRING_DATASOURCE_DATA
211-
+ " does, it accepts the name of the file containing the SQL statements to execute when when Hibernate ORM starts.\n";
211+
+ " does, it accepts the name of files containing the SQL statements to execute when Hibernate ORM starts.\n";
212212
break;
213213
default:
214-
notSupportedProperties = notSupportedProperties + "\t- " + sp + "\n";
214+
notSupportedProperties = notSupportedProperties + "\t- " + sp + " does not have a Quarkus equivalent\n";
215215
break;
216216
}
217217
}

integration-tests/spring-data-jpa/src/test/java/io/quarkus/it/spring/data/jpa/PropertyWarningsPMT.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public void ensureProperQuarkusPropertiesLogged() {
4242
.contains(
4343
"spring.jpa.hibernate.naming.implicit-strategy should be replaced by quarkus.hibernate-orm.implicit-naming-strategy")
4444
.contains(
45-
"quarkus.hibernate-orm.sql-load-script could be used to load data instead of spring.datasource.data but it does not support either comma separated list of resources or resources with ant-style patterns as spring.datasource.data does, it accepts the name of the file containing the SQL statements to execute when when Hibernate ORM starts");
45+
"quarkus.hibernate-orm.sql-load-script could be used to load data instead of spring.datasource.data but it does not support ant-style patterns as spring.datasource.data does, it accepts the name of files containing the SQL statements to execute when Hibernate ORM starts");
4646
});
4747
});
4848
});

0 commit comments

Comments
 (0)