PropertySourcesPlaceHolderConfigurer等效于PropertyOverrideConfigurer

时间:2015-04-28 11:16:58

标签: java spring spring-3

PropertySourcesPlaceHolderConfigurer可以从属性来源查找占位符的值。是否有与PropertyOverrideConfigurer相同的东西,它使用属性源来覆盖属性定义?

1 个答案:

答案 0 :(得分:0)

    <bean class="org.springframework.beans.factory.config.PropertyOverrideConfigurer>
        <property name="location" value="file:${your_property_from_PropertySourcePlaceholderConfigurer}/override.properties"/>
        <property name="localOverride" value="true" />
    </bean>