camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clinton <clint.pe...@ionep.com>
Subject Referencing an exchange property from xpath predicate in spring dsl
Date Fri, 28 Nov 2014 17:45:56 GMT
I am trying to use xpath in a "loop" stmt, such that the "CamelLoopIndex"
(+1) can be used as a predicate to select a repeating segment from the msg
body.  I haven't been able to get anything to work.

Getting error:
Caused by: javax.xml.xpath.XPathExpressionException:
net.sf.saxon.trans.XPathException: expected "<name>", found "{"

Any help appreciated!

<loop>
<simple>${property.rqstDistribution.size}</simple>

<setProperty propertyName="myRepeatingSegmentPos">
     <simple>${property.CamelLoopIndex} + 1</simple>
</setProperty>
<setProperty propertyName="myRepeatingSegment">
	<xpath
saxon="true">/*/ns1:TheRepeatingSegment[function:simple(${property.myRepeatingSegmentPos})]</xpath>
</setProperty>
--other logic follows--
</loop>



--
View this message in context: http://camel.465427.n5.nabble.com/Referencing-an-exchange-property-from-xpath-predicate-in-spring-dsl-tp5759777.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message