diff --git a/spring-context/src/main/java/org/springframework/context/annotation/PropertySource.java b/spring-context/src/main/java/org/springframework/context/annotation/PropertySource.java index 2f7ae8a5e5..75d9fc6b8f 100644 --- a/spring-context/src/main/java/org/springframework/context/annotation/PropertySource.java +++ b/spring-context/src/main/java/org/springframework/context/annotation/PropertySource.java @@ -184,13 +184,14 @@ public @interface PropertySource { *
The default {@link #factory() factory} supports both traditional and * XML-based properties file formats — for example, * {@code "classpath:/com/myco/app.properties"} or {@code "file:/path/to/file.xml"}. - *
Resource location wildcards (e.g. **/*.properties) are not permitted; - * each location must evaluate to exactly one resource. - *
${...} placeholders will be resolved against property sources already + *
As of Spring Framework 6.1, resource location wildcards are also + * supported — for example, {@code "classpath*:/config/*.properties"}. + *
{@code ${...}} placeholders will be resolved against property sources already * registered with the {@code Environment}. See {@linkplain PropertySource above} * for examples. *
Each location will be added to the enclosing {@code Environment} as its own - * property source, and in the order declared. + * property source, and in the order declared (or in the order in which resource + * locations are resolved when location wildcards are used). */ String[] value();