Skip to content

Commit

Permalink
Restore customization of PropertyResolver
Browse files Browse the repository at this point in the history
This commit reintroduces the ability to customize the PropertyResolver
to use in PropertySourcesPropertyResolver

See gh-26761
  • Loading branch information
1zg12 authored and snicoll committed Aug 26, 2023
1 parent 89b7a6b commit 00fffb7
Showing 1 changed file with 8 additions and 1 deletion.
Expand Up @@ -170,10 +170,17 @@ public String getProperty(String key) {
}
}

processProperties(beanFactory, new PropertySourcesPropertyResolver(this.propertySources));
processProperties(beanFactory, getPropertyResolver(this.propertySources));
this.appliedPropertySources = this.propertySources;
}

/**
* Construct and provide a PropertyResolver from the given properties.
*/
public ConfigurablePropertyResolver getPropertyResolver(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.
Expand Down

0 comments on commit 00fffb7

Please sign in to comment.