Merge pull request #26761 from 1zg12
* pr/26761: Polish "Restore customization of PropertyResolver" Restore customization of PropertyResolver Closes gh-26761
This commit is contained in:
commit
2b3539a6de
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2022 the original author or authors.
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
|
@ -170,10 +170,19 @@ public class PropertySourcesPlaceholderConfigurer extends PlaceholderConfigurerS
|
|||
}
|
||||
}
|
||||
|
||||
processProperties(beanFactory, new PropertySourcesPropertyResolver(this.propertySources));
|
||||
processProperties(beanFactory, createPropertyResolver(this.propertySources));
|
||||
this.appliedPropertySources = this.propertySources;
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a {@link ConfigurablePropertyResolver} for the specified property sources.
|
||||
* @param propertySources the property sources to use
|
||||
* @since 6.0.12
|
||||
*/
|
||||
protected ConfigurablePropertyResolver createPropertyResolver(MutablePropertySources propertySources){
|
||||
return new PropertySourcesPropertyResolver(propertySources);
|
||||
}
|
||||
|
||||
/**
|
||||
* Visit each bean definition in the given bean factory and attempt to replace ${...} property
|
||||
* placeholders with values from the given properties.
|
||||
|
|
|
|||
Loading…
Reference in New Issue