activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From 1gnition <ori....@gmail.com>
Subject ActiveMQ cannot resolve environment variables in activemq.xml
Date Thu, 12 Feb 2015 11:21:29 GMT
Hi,I have defined a bean in activemq.xml with a placeholder for environment
variable:
&lt;bean id="sqlserverDataSource"
class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close"&gt;       
&lt;property name="driverClassName"
value="net.sourceforge.jtds.jdbc.Driver"/&gt;        &lt;property name="url"
value="jdbc:jtds:sqlserver://*${RDB_ADDRESS}*:1433"/&gt;       
...&lt;/bean&gt;
I added the following property to the PropertyPlaceholderConfigurerBean:
&lt;property name="systemEnvironment" value="true"/&gt;
And even though, I get the following exception:
2015-02-12 13:20:01,796 | ERROR | Failed to load: class path resource
[activemq.xml], reason:Invalid bean definition with name
'sqlserverDataSource' defined in class path resource [activemq.xml]:*Could
not resolve placeholder 'RDB_ADDRESS'* in string
value"jdbc:jtds:sqlserver://${RDB_ADDRESS}:1433" |
org.apache.activemq.xbean.XBeanBrokerFactory
|mainorg.springframework.beans.factory.BeanDefinitionStoreException: Invalid
bean definition with name'sqlserverDataSource' defined in class path
resource [activemq.xml]: Could not resolve placeholder'RDB_ADDRESS' in
string value "jdbc:jtds:sqlserver://${RDB_ADDRESS}:1433"
Any idea why it happens?



--
View this message in context: http://activemq.2283324.n4.nabble.com/ActiveMQ-cannot-resolve-environment-variables-in-activemq-xml-tp4691435.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message