Doh! After several hours of debugging (which was interesting anyway) I realized that I confused Properties and Headers! Now it works fine :)
I used message modification to debug it, like this: <setBody> <el>${in.headers.size}'</el> </setBody> Vadim. On Tue, Aug 26, 2008 at 1:25 AM, Claus Ibsen <[EMAIL PROTECTED]> wrote: > Hi Vadim > > Do you still have an issue with the el filter? > I would suggest to try using a simpler expression to test that the == > operator works as expected > > <el>'kickoff' == 'kickoff'</el> > > > > Med venlig hilsen > > Claus Ibsen > ...................................... > Silverbullet > Skovsgårdsvænget 21 > 8362 Hørning > Tlf. +45 2962 7576 > Web: www.silverbullet.dk > > -----Original Message----- > From: Vadim Chekan [mailto:[EMAIL PROTECTED] > Sent: 23. august 2008 10:10 > To: camel-user@activemq.apache.org > Subject: Filter > > Hi all, > Another question. > In camel-1.4 I have configuration: > > <route> > <from uri="timer://kickoff?period=10000&delay=1"/> > <setBody><constant>bla-bla</constant></setBody> > <filter> > <el>${in.headers['org.apache.camel.timer.name'] == > 'kickoff'}</el> > <to uri='mock:filtered'/> > </filter> > </route> > > And here is the trace: > 2008-08-23 07:51:01,768 [d=10000&delay=1] INFO TraceInterceptor > - ID-ubuntu/45497-1219477861659/1-0 -> interceptor1 > Interceptor[Delegate(Pipeline[DeadLetterChannel[Delegate(TraceInterceptor[SetBody[ > constantExpression[bla-bla]]]), > RecipientList[log:org.apache.camel.DeadLetterChannel?level=error], > RedeliveryPolicy[maximumRedeliveries=6]], > DeadLetterChannel[Delegate(TraceInterceptor[Filter[ > elExpression[${in.headers['org.apache.camel.timer.name'] == 'kickoff'}] > -> [To[mock:filtered]]]]), > RecipientList[log:org.apache.camel.DeadLetterChannel?level=error], > RedeliveryPolicy[maximumRedeliveries=6]]])] InOnly > Properties:{org.apache.camel.timer.name=kickoff, > org.apache.camel.timer.period=10000} Headers:{} BodyType:null > Body:Message: null > > 2008-08-23 07:51:01,776 [d=10000&delay=1] INFO TraceInterceptor > - ID-ubuntu/45497-1219477861659/1-0 -> setBody1 SetBody[ > constantExpression[bla-bla]] InOnly > Properties:{org.apache.camel.timer.name=kickoff, > org.apache.camel.timer.period=10000} Headers:{} BodyType:null > Body:Message: null > > 2008-08-23 07:51:01,777 [d=10000&delay=1] INFO TraceInterceptor > - ID-ubuntu/45497-1219477861659/1-0 -> filter1 Filter[ > elExpression[${in.headers['org.apache.camel.timer.name'] == 'kickoff'}] > -> [To[mock:filtered]]] InOnly > Properties:{org.apache.camel.timer.name=kickoff, > org.apache.camel.timer.period=10000} Headers:{} BodyType:String Body:bla-bla > > So message does not make it through the filter. If I replace "==" to > "!=" then it works. But trace shows that this header is present in the > message. Any ideas? > > > Vadim. > -- >From RFC 2631: In ASN.1, EXPLICIT tagging is implicit unless IMPLICIT is explicitly specified