PDA

View Full Version : PropertyPlaceHolderConfigurer - problem with specification of location?



madhav
Apr 5th, 2006, 12:45 AM
Hi all,
While using activemq jms with spring, I came across a problem related to specifying location property.
The following bean definition for PropertyPlaceholderConfigurer DIDNT WORK.

<bean class="org.springframework.beans.factory.config.PropertyP laceholderConfigurer">
<property name="location">
<value>classpath:mydir/my.properties</value>
</property>
</bean>

But the following bean definition WORKS !!!

<bean class="org.springframework.beans.factory.config.PropertyP laceholderConfigurer">
<property name="location" value="classpath:mydir/my.properties" />
</bean>

Any ideas?


Thanks a lot :)
-Madhav

Andreas Senft
Apr 5th, 2006, 12:58 AM
Seems to be the same to me. The only issue I can think of, is that leading/trailing whitespace might be relevant when using the <value> tags (though not sure about this). However, in your provided example it seems to be ok.

Regards,
Andreas