I ran into a simple problem here. I have two properties files that I want to read in order to create two data sources. But these property files have exactly the same keys! I can read both files using:
<context:property-placeholder location="classpath:foo1.properties,classpath:foo2.properties"/>
But then I can not access the correct value:
<bean id="myDataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close"> <property name="driverClassName" value="${driver}" /> <property name="url" value="${url}" /> ... </bean>
How can I read my properties to use variables like ${foo1.driver}
and know which one is being called?
Thanks for the help!
source share