On Thu, Sep 17, 2009 at 7:06 PM, Winsks <[email protected]> wrote:
>
> Thanks for the info... I am able to do that now with the help of
> <camel:convertBodyTo type="java.lang.String" /> tag along the route to
> convert the SOAPMessage to string...
> I have an other doubt; While configuring Camel CxF endpoints through spring
> configuration like below,
>
> <cxf:cxfEndpoint id="serviceEndPoint"
> address="http://localhost:8080/websvc/JaxWsService"
> serviceClass="com.websvc.jaxws.JaxWs"/>
>
> Are there any way of configuring URL host/port dynamically in Spring
> configuration ?
> any link to tutorial to test case would help..
Use a PropertyPlaceholderConfigurer for that -
<bean id="propertyConfigurer"
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="location" value="classpath:myconfig.properties"/>
</bean>
<cxf:cxfEndpoint id="serviceEndPoint"
address="http://${some.host}:${some.port}/websvc/JaxWsService"
serviceClass="com.websvc.jaxws.JaxWs"/>
where "myconfig.properties" would contain -
some.host=localhost
some.port=8080