You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Olivier Lamy <ol...@apache.org> on 2013/04/03 13:50:58 UTC

placeholder in from uri

Hi,

I'd like to be able to use something like:

<from uri="{{productImport.uri.location}}" />

But I have issues with that.
Exception:
Caused by: org.apache.camel.NoSuchEndpointException: No endpoint could
be found for: {{productImport.uri.location}}, please check your
classpath contains the needed Camel component jar.

more details available here: https://gist.github.com/olamy/5298824

Is it possible to use a placeholder for the whole uri ?
Or the scheme (sftp, etc) is a minimum requited ?

Thanks
--
Olivier Lamy
Ecetera: http://ecetera.com.au
http://twitter.com/olamy | http://linkedin.com/in/olamy

Re: placeholder in from uri

Posted by Claus Ibsen <cl...@gmail.com>.
Yes that is supported.

See this FAQ why you can't use springs ${ } directly
http://camel.apache.org/how-do-i-use-spring-property-placeholder-with-camel-xml.html

And I guess you have already seen some of the information on
http://camel.apache.org/using-propertyplaceholder.html

On Thu, Apr 4, 2013 at 12:04 AM, Olivier Lamy <ol...@apache.org> wrote:
> Ok for the nested properties.
> But my other question concerns usage of property in from uri.
> <from uri="{{productImport.uri.location}}" />
> Is that supported ? It looks the scheme is a minimum.
>
>
>
> 2013/4/3 Claus Ibsen <cl...@gmail.com>:
>> Hi
>>
>> You can use {{ }} in the .properties file then Camel will pick that up.
>>
>> Support for using nested Spring ${ } is being tracked by
>> https://issues.apache.org/jira/browse/CAMEL-6233
>>
>> And added in upcoming releases.
>>
>>
>> On Wed, Apr 3, 2013 at 1:50 PM, Olivier Lamy <ol...@apache.org> wrote:
>>> Hi,
>>>
>>> I'd like to be able to use something like:
>>>
>>> <from uri="{{productImport.uri.location}}" />
>>>
>>> But I have issues with that.
>>> Exception:
>>> Caused by: org.apache.camel.NoSuchEndpointException: No endpoint could
>>> be found for: {{productImport.uri.location}}, please check your
>>> classpath contains the needed Camel component jar.
>>>
>>> more details available here: https://gist.github.com/olamy/5298824
>>>
>>> Is it possible to use a placeholder for the whole uri ?
>>> Or the scheme (sftp, etc) is a minimum requited ?
>>>
>>> Thanks
>>> --
>>> Olivier Lamy
>>> Ecetera: http://ecetera.com.au
>>> http://twitter.com/olamy | http://linkedin.com/in/olamy
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> Red Hat, Inc.
>> FuseSource is now part of Red Hat
>> Email: cibsen@redhat.com
>> Web: http://fusesource.com
>> Twitter: davsclaus
>> Blog: http://davsclaus.com
>> Author of Camel in Action: http://www.manning.com/ibsen
>
>
>
> --
> Olivier Lamy
> Ecetera: http://ecetera.com.au
> http://twitter.com/olamy | http://linkedin.com/in/olamy



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cibsen@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: placeholder in from uri

Posted by Christian Müller <ch...@gmail.com>.
Hello Olivier!

May be this unit test is helpful for you:

https://svn.apache.org/repos/asf/camel/trunk/tests/camel-itest-osgi/src/test/java/org/apache/camel/itest/osgi/blueprint/CamelBlueprint3Test.java
https://svn.apache.org/repos/asf/camel/trunk/tests/camel-itest-osgi/src/test/resources/org/apache/camel/itest/osgi/blueprint/blueprint-8.xml
https://svn.apache.org/repos/asf/camel/trunk/tests/camel-itest-osgi/src/test/resources/org/apache/camel/itest/osgi/blueprint/cheese.properties

Best,
Christian


On Thu, Apr 4, 2013 at 12:04 AM, Olivier Lamy <ol...@apache.org> wrote:

> Ok for the nested properties.
> But my other question concerns usage of property in from uri.
> <from uri="{{productImport.uri.location}}" />
> Is that supported ? It looks the scheme is a minimum.
>
>
>
> 2013/4/3 Claus Ibsen <cl...@gmail.com>:
> > Hi
> >
> > You can use {{ }} in the .properties file then Camel will pick that up.
> >
> > Support for using nested Spring ${ } is being tracked by
> > https://issues.apache.org/jira/browse/CAMEL-6233
> >
> > And added in upcoming releases.
> >
> >
> > On Wed, Apr 3, 2013 at 1:50 PM, Olivier Lamy <ol...@apache.org> wrote:
> >> Hi,
> >>
> >> I'd like to be able to use something like:
> >>
> >> <from uri="{{productImport.uri.location}}" />
> >>
> >> But I have issues with that.
> >> Exception:
> >> Caused by: org.apache.camel.NoSuchEndpointException: No endpoint could
> >> be found for: {{productImport.uri.location}}, please check your
> >> classpath contains the needed Camel component jar.
> >>
> >> more details available here: https://gist.github.com/olamy/5298824
> >>
> >> Is it possible to use a placeholder for the whole uri ?
> >> Or the scheme (sftp, etc) is a minimum requited ?
> >>
> >> Thanks
> >> --
> >> Olivier Lamy
> >> Ecetera: http://ecetera.com.au
> >> http://twitter.com/olamy | http://linkedin.com/in/olamy
> >
> >
> >
> > --
> > Claus Ibsen
> > -----------------
> > Red Hat, Inc.
> > FuseSource is now part of Red Hat
> > Email: cibsen@redhat.com
> > Web: http://fusesource.com
> > Twitter: davsclaus
> > Blog: http://davsclaus.com
> > Author of Camel in Action: http://www.manning.com/ibsen
>
>
>
> --
> Olivier Lamy
> Ecetera: http://ecetera.com.au
> http://twitter.com/olamy | http://linkedin.com/in/olamy
>

Re: placeholder in from uri

Posted by Olivier Lamy <ol...@apache.org>.
Ok for the nested properties.
But my other question concerns usage of property in from uri.
<from uri="{{productImport.uri.location}}" />
Is that supported ? It looks the scheme is a minimum.



2013/4/3 Claus Ibsen <cl...@gmail.com>:
> Hi
>
> You can use {{ }} in the .properties file then Camel will pick that up.
>
> Support for using nested Spring ${ } is being tracked by
> https://issues.apache.org/jira/browse/CAMEL-6233
>
> And added in upcoming releases.
>
>
> On Wed, Apr 3, 2013 at 1:50 PM, Olivier Lamy <ol...@apache.org> wrote:
>> Hi,
>>
>> I'd like to be able to use something like:
>>
>> <from uri="{{productImport.uri.location}}" />
>>
>> But I have issues with that.
>> Exception:
>> Caused by: org.apache.camel.NoSuchEndpointException: No endpoint could
>> be found for: {{productImport.uri.location}}, please check your
>> classpath contains the needed Camel component jar.
>>
>> more details available here: https://gist.github.com/olamy/5298824
>>
>> Is it possible to use a placeholder for the whole uri ?
>> Or the scheme (sftp, etc) is a minimum requited ?
>>
>> Thanks
>> --
>> Olivier Lamy
>> Ecetera: http://ecetera.com.au
>> http://twitter.com/olamy | http://linkedin.com/in/olamy
>
>
>
> --
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> FuseSource is now part of Red Hat
> Email: cibsen@redhat.com
> Web: http://fusesource.com
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen



-- 
Olivier Lamy
Ecetera: http://ecetera.com.au
http://twitter.com/olamy | http://linkedin.com/in/olamy

Re: placeholder in from uri

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

You can use {{ }} in the .properties file then Camel will pick that up.

Support for using nested Spring ${ } is being tracked by
https://issues.apache.org/jira/browse/CAMEL-6233

And added in upcoming releases.


On Wed, Apr 3, 2013 at 1:50 PM, Olivier Lamy <ol...@apache.org> wrote:
> Hi,
>
> I'd like to be able to use something like:
>
> <from uri="{{productImport.uri.location}}" />
>
> But I have issues with that.
> Exception:
> Caused by: org.apache.camel.NoSuchEndpointException: No endpoint could
> be found for: {{productImport.uri.location}}, please check your
> classpath contains the needed Camel component jar.
>
> more details available here: https://gist.github.com/olamy/5298824
>
> Is it possible to use a placeholder for the whole uri ?
> Or the scheme (sftp, etc) is a minimum requited ?
>
> Thanks
> --
> Olivier Lamy
> Ecetera: http://ecetera.com.au
> http://twitter.com/olamy | http://linkedin.com/in/olamy



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cibsen@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen