Commit b8dc4e74 authored by Stephane Nicoll's avatar Stephane Nicoll

Deprecate ConfigurationProperties#location

Closes gh-5129
parent 58e8e10a
...@@ -90,7 +90,9 @@ public @interface ConfigurationProperties { ...@@ -90,7 +90,9 @@ public @interface ConfigurationProperties {
* defined in the environment. * defined in the environment.
* @return the path (or paths) of resources to bind to * @return the path (or paths) of resources to bind to
* @see #merge() * @see #merge()
* @deprecated configure the environment with those additional locations instead
*/ */
@Deprecated
String[] locations() default {}; String[] locations() default {};
/** /**
...@@ -98,7 +100,9 @@ public @interface ConfigurationProperties { ...@@ -98,7 +100,9 @@ public @interface ConfigurationProperties {
* merged with the default configuration. * merged with the default configuration.
* @return the flag value (default true) * @return the flag value (default true)
* @see #locations() * @see #locations()
* @deprecated as {@link #locations()} is deprecated as well
*/ */
@Deprecated
boolean merge() default true; boolean merge() default true;
} }
...@@ -302,6 +302,7 @@ public class ConfigurationPropertiesBindingPostProcessor ...@@ -302,6 +302,7 @@ public class ConfigurationPropertiesBindingPostProcessor
return bean; return bean;
} }
@SuppressWarnings("deprecation")
private void postProcessBeforeInitialization(Object bean, String beanName, private void postProcessBeforeInitialization(Object bean, String beanName,
ConfigurationProperties annotation) { ConfigurationProperties annotation) {
Object target = bean; Object target = bean;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment