In a property file, I config the username and password, besides the endpoint
url, as below
#This used to access the activemq
userName=system
password=manager
#This used to set the url of endpoint
url1=restlet:/rs/his/...
url2=...
I config the router by {{url1}}, and the activemq infomation
with{{userName}}, {{password}}
<bean id="activemqTCP"
class="org.apache.activemq.camel.component.ActiveMQComponent">
<property name="preserveMessageQos" value="true"></property>
<property name="transacted" value="true" />
<property name="transactionManager" ref="txManager" />
<property name="userName" value="{{userName}}" />
<property name="password" value="{{password}}" />
</bean>
when routing, it tell me "UncategorizedJmsException" Occured, but without
the placeholder, using the plain text in config file worked well. as below
<bean id="activemqTCP"
class="org.apache.activemq.camel.component.ActiveMQComponent">
<property name="preserveMessageQos" value="true"></property>
<property name="transacted" value="true" />
<property name="transactionManager" ref="txManager" />
<property name="userName" value="system" />
<property name="password" value="manager" />
</bean>
So I want to know whether the camel property component can used for config
the information not for routing. And whether the expression {{XXX}} only be
parsed when router buliding.
--
View this message in context:
http://camel.465427.n5.nabble.com/how-to-use-the-org-apache-camel-component-properties-PropertiesComponent-tp5742750p5742757.html
Sent from the Camel - Users mailing list archive at Nabble.com.