camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jacobsen, Jasen W." <>
Subject Set Body to Array?
Date Fri, 17 Mar 2017 21:28:47 GMT
I've done some Googling but can't quite find the answer so here goes...

I have a REST service defined using blueprint XML:

<from id="_from1" uri="rest:get:myService/{param1}/{param2}"/>

For various reasons, I'd like to access "param2" in a later route using:


So the body needs to be transformed into a list of maps.

I defined a bean with this structure at the top of my XML:

<bean id="bodyList" class="java.util.ArrayList">
    <list value-type="java.util.HashMap">

That gives me a bean I can reference and... Somehow put the value of
param2 into it. That's the step I can't figure out. How to set the value
of the param2_key map within the route and then set the bean to be the

If I:


The body gets the bean, but the bean does not have param2 set.

Thanks for any help.

- Jasen.

View raw message