Hi

I've got a small problem with "content-based-router". I would like to
send message which has a priority 1 to pipeline1 and message which has
a priority 0 to pipeline2, but everything I send it goes to pipeline2.
Is this a good configuriation "content-based-router"?

Mario

xbean.xml file:
 <eip:content-based-router service="Guest:router" endpoint="router">
   <eip:rules>
     <eip:routing-rule>
       <eip:predicate>
         <eip:xpath-predicate xpath="/tns:Guest/@priority = '1'"/>
       </eip:predicate>
       <eip:target>
         <eip:exchange-target service="Guest:pipeline1" endpoint="pipeline1"
/>
       </eip:target>
     </eip:routing-rule>
     <eip:routing-rule>

       <eip:target>
         <eip:exchange-target service="Guest:pipeline2" endpoint="pipeline2"
/>
       </eip:target>
     </eip:routing-rule>
   </eip:rules>
 </eip:content-based-router>

 <eip:xpath-splitter service="airClient:xpathSplitter"
endpoint="xpath" xpath="/AirClients/*">
   <eip:target>
     <eip:exchange-target service="airClient:router" endpoint="router" />
   </eip:target>
  </eip:xpath-splitter>

XML messages which is sended across spliter to router
<?xml version='1.0' encoding='UTF-8'?>
<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'
xmlns:tns='http://esbtoolkit.com/service2/types'>
<env:Body>
<Guests>
 <tns:Guest>
   <tns:priority>0</tns:priority>
   <tns:surname>Smith</tns:surname>
 </tns:Guest>
 <tns:Guest>
   <tns:priority>1</tns:priority>
   <tns:surname>Johnson</tns:surname>
 </tns:Guest>
 </Guests>
</env:Body>
</env:Envelope>
-- 
View this message in context: 
http://www.nabble.com/Content-based-router---problem-with-direction-tp16650238p16650238.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Reply via email to