You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by ramnar <ra...@gmail.com> on 2012/04/09 11:38:47 UTC

PropertyPlaceholder location identifier

Hi
I have a bundle having camelcontext using propertyplaceholder to refer some
properties as shown below
/<camel:camelContext id="example">
	<propertyPlaceholder id="properties" location="?"
xmlns="http://camel.apache.org/schema/spring"/>
		<camel:route id="route1">
			<camel:from uri="file:///{{sender.uri}}" />
			<camel:to uri="file:///{{receiver.uri}}" />
		</camel:route>
	</camel:camelContext>/

The properties "sender.uri" and "receiver.uri" are defined in a file
"data.properties" in *another bundle* .My question is how can I define the
location in the camelcontext so that it identifies the "data.properties"
file

My reasoning for placing properties file in another bundle is that if the
properties are changed I can just update the properties bundle rather than
reloading the entire route.Thanks in advance





--
View this message in context: http://camel.465427.n5.nabble.com/PropertyPlaceholder-location-identifier-tp5627066p5627066.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: PropertyPlaceholder location identifier

Posted by Stefan Burkard <sb...@gmail.com>.
Does this help? (see section "Use OSGi configuration properties")
http://fusesource.com/docs/esb/4.2/deploy_osgi/DeployCamel-Packaging.html

stefan

On Mon, Apr 9, 2012 at 11:38, ramnar <ra...@gmail.com> wrote:
> Hi
> I have a bundle having camelcontext using propertyplaceholder to refer some
> properties as shown below
> /<camel:camelContext id="example">
>        <propertyPlaceholder id="properties" location="?"
> xmlns="http://camel.apache.org/schema/spring"/>
>                <camel:route id="route1">
>                        <camel:from uri="file:///{{sender.uri}}" />
>                        <camel:to uri="file:///{{receiver.uri}}" />
>                </camel:route>
>        </camel:camelContext>/
>
> The properties "sender.uri" and "receiver.uri" are defined in a file
> "data.properties" in *another bundle* .My question is how can I define the
> location in the camelcontext so that it identifies the "data.properties"
> file
>
> My reasoning for placing properties file in another bundle is that if the
> properties are changed I can just update the properties bundle rather than
> reloading the entire route.Thanks in advance
>
>
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/PropertyPlaceholder-location-identifier-tp5627066p5627066.html
> Sent from the Camel - Users mailing list archive at Nabble.com.

Re: PropertyPlaceholder location identifier

Posted by Christian Müller <ch...@gmail.com>.
Do you have any good reason to not put a properties file in the class path
(e.g. the /etc subdirectory if you use Karaf or ServiceMix)?

Best,
Christian

On Mon, Apr 9, 2012 at 11:38 AM, ramnar <ra...@gmail.com> wrote:

> Hi
> I have a bundle having camelcontext using propertyplaceholder to refer some
> properties as shown below
> /<camel:camelContext id="example">
>        <propertyPlaceholder id="properties" location="?"
> xmlns="http://camel.apache.org/schema/spring"/>
>                <camel:route id="route1">
>                        <camel:from uri="file:///{{sender.uri}}" />
>                        <camel:to uri="file:///{{receiver.uri}}" />
>                </camel:route>
>        </camel:camelContext>/
>
> The properties "sender.uri" and "receiver.uri" are defined in a file
> "data.properties" in *another bundle* .My question is how can I define the
> location in the camelcontext so that it identifies the "data.properties"
> file
>
> My reasoning for placing properties file in another bundle is that if the
> properties are changed I can just update the properties bundle rather than
> reloading the entire route.Thanks in advance
>
>
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/PropertyPlaceholder-location-identifier-tp5627066p5627066.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>