FAQ
Hi,

I am trying to create a custom component with URI parameters. I haven't
found an example that shows the full implementation of this kind of
component so I modified the example from the Camel in Action book in order
to add a URI parameter. To do so, I modified the following classes:

HelloWorldEndpoint - added the following lines



HelloWorldComponentTest - modified the return new RouteBuilder() method:


The thing is that when I try to retrieve the value of "param" in the
Producer (using exchange.getProperties()) it is not there.



What am I doing wrong?

Thanks,




--
View this message in context: http://camel.465427.n5.nabble.com/Creation-of-a-Custom-Component-with-URI-parameters-tp5760889.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Search Discussions

  • Claus Ibsen at Dec 19, 2014 at 6:11 am

    On Thu, Dec 18, 2014 at 8:25 PM, IgnatiusReilly wrote:
    Hi,

    I am trying to create a custom component with URI parameters. I haven't
    found an example that shows the full implementation of this kind of
    component so I modified the example from the Camel in Action book in order
    to add a URI parameter. To do so, I modified the following classes:

    HelloWorldEndpoint - added the following lines



    HelloWorldComponentTest - modified the return new RouteBuilder() method:


    The thing is that when I try to retrieve the value of "param" in the
    Producer (using exchange.getProperties()) it is not there.
    Those are 2 different things. The value is an option on the endpoint.
    So you can access the value from the producer, where you can put the
    value on the exchange, anywhere you like. Though usually as a header.



    What am I doing wrong?

    Thanks,




    --
    View this message in context: http://camel.465427.n5.nabble.com/Creation-of-a-Custom-Component-with-URI-parameters-tp5760889.html
    Sent from the Camel - Users mailing list archive at Nabble.com.


    --
    Claus Ibsen
    -----------------
    Red Hat, Inc.
    Email: cibsen@redhat.com
    Twitter: davsclaus
    Blog: http://davsclaus.com
    Author of Camel in Action: http://www.manning.com/ibsen
    hawtio: http://hawt.io/
    fabric8: http://fabric8.io/
  • IgnatiusReilly at Dec 19, 2014 at 1:40 pm
    Hi Claus,

    Thanks for your quick answer. I was able to retrieve the value from in the
    producer from the endpoint.

    IR





    --
    View this message in context: http://camel.465427.n5.nabble.com/Creation-of-a-Custom-Component-with-URI-parameters-tp5760889p5760925.html
    Sent from the Camel - Users mailing list archive at Nabble.com.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupusers @
categoriescamel
postedDec 18, '14 at 7:25p
activeDec 19, '14 at 1:40p
posts3
users2
websitecamel.apache.org

2 users in discussion

IgnatiusReilly: 2 posts Claus Ibsen: 1 post

People

Translate

site design / logo © 2021 Grokbase