camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From titexe <tit...@yahoo.Fr>
Subject Re: Filtering with the simple expression does not work ?
Date Fri, 09 Oct 2009 09:20:08 GMT

you're right, the term simply does not support operators, problem solved in
version 2.0 Camel.

http://fusesource.com/issues/browse/MR-176

Otherwise, I solved the problem by using other language class message filter

as el  or jxpath, it works very well with the camel version 1.6.

thank you for your cooperation.

Best regards,

titexe



Claus Ibsen-2 wrote:
> 
> Hi
> 
> The simple language does NOT support operators in Camel 1.x.
> This feature requires to use Camel 2.0.
> 
> You have to use something else such as mvel, ognl, groovy or a regular
> bean for the testing.
> 
> Or upgrade to Camel 2.0 and use Simple.
> 
> 
> On Thu, Oct 8, 2009 at 6:41 PM, titexe <AbdellatifBOUCHAMA@eurofins.com>
> wrote:
>>
>> Hello,
>>
>> My route is simple, I have a incoming queue (IN), All messages received
>> in
>> this queue is routed to XML Queue or CSV Queue according to the following
>> condition:
>>
>> If the Action field located in the header of the message as field
>> properties
>> (Message Properties) is equal to XML or CSV
>>
>> This route does not work using the simple expression?
>>
>> Below my configuration:
>>
>> <camelContext id="camel" trace="true"
>> xmlns="http://activemq.apache.org/camel/schema/spring">
>> <route>
>>        <from uri="activemq:queue:IN"/>
>>                <choice>
>>                <when>
>>                                <simple>${in.header.Action}
==
>> 'XML'</simple>
>>                                <to uri="activemq:queue:XML"/>
>>                </when>
>>                <when>
>>                                <simple>${in.header.Action}
==
>> 'CSV'</simple>
>>                                <to uri="activemq:queue:CSV"/>
>>                </when>
>>                <otherwise>
>>                    <to uri="activemq:queue:ERROR"/>
>>                </otherwise>
>>            </choice>
>> </route>
>> </camelContext>
>>
>> Version Camel : 1.6.1
>> Version Java    : 1.6
>> Version Activemq : fuse message broker 5.3.0.3
>>
>> Thank you in advance
>>
>> Best regards,
>>
>> titexe
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Filtering-with-the-simple-expression-does-not-work---tp25803293p25803293.html
>> Sent from the Camel - Users mailing list archive at Nabble.com.
>>
>>
> 
> 
> 
> -- 
> Claus Ibsen
> Apache Camel Committer
> 
> Open Source Integration: http://fusesource.com
> Blog: http://davsclaus.blogspot.com/
> Twitter: http://twitter.com/davsclaus
> 
> 

-- 
View this message in context: http://www.nabble.com/Filtering-with-the-simple-expression-does-not-work---tp25803293p25817984.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Mime
View raw message