camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William Tam" <email.w...@gmail.com>
Subject Content Based Router Spring XML
Date Thu, 11 Oct 2007 04:32:23 GMT
The XML config example in the doc seems to be obsolete
http://activemq.apache.org/camel/content-based-router.html.  I am
trying to use the Simple language support.  Does "${in.header.foo} =
'bar'" look right?  I am trying to say "if in.header foo equals to
'bar'".  It does not seem to work.

Thanks,
William

 <route>
            <from uri="seda:a"/>
            <choice>
                <when>
                    <simple>${in.header.foo} = 'bar'</simple>
                    <to uri="seda:b"/>
                </when>

                <when>
                    <simple>${in.header.foo} = 'cheese'</simple>
    	            <to uri="seda:c"/>
                </when>

                <otherwise>
                    <to uri="seda:d"/>
                </otherwise>
            </choice>
        </route>

Mime
View raw message