Return-Path: X-Original-To: apmail-camel-users-archive@www.apache.org Delivered-To: apmail-camel-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 6403D9347 for ; Mon, 4 Jun 2012 07:00:56 +0000 (UTC) Received: (qmail 5932 invoked by uid 500); 4 Jun 2012 07:00:56 -0000 Delivered-To: apmail-camel-users-archive@camel.apache.org Received: (qmail 5566 invoked by uid 500); 4 Jun 2012 07:00:54 -0000 Mailing-List: contact users-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@camel.apache.org Delivered-To: mailing list users@camel.apache.org Delivered-To: moderator for users@camel.apache.org Received: (qmail 20140 invoked by uid 99); 4 Jun 2012 05:33:27 -0000 X-ASF-Spam-Status: No, hits=3.0 required=5.0 tests=FORGED_YAHOO_RCVD,SPF_NEUTRAL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Date: Sun, 3 Jun 2012 22:33:00 -0700 (PDT) From: addict To: users@camel.apache.org Message-ID: <1338787980560-5713919.post@n5.nabble.com> Subject: Problem with Java DSL filter MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit public class Test extends RouteBuilder { private volatile String tag = null; @Override public void configure() throws Exception { from("http://url/a.csv") .filter(header("Tag").isNotNull()) .filter(header("Tag").isNotEqualTo(tag)) .process(new Processor() { @Override public void process(Exchange exchange) throws Exception { String s = String.valueOf(exchange.getIn().getHeader( "Tag")); etag = new String(s); System.out.println(tag); } }).to("file://c:/test/"); } } However the comparison always pick up the tag value as null. Can anybody help -- View this message in context: http://camel.465427.n5.nabble.com/Problem-with-Java-DSL-filter-tp5713919.html Sent from the Camel - Users mailing list archive at Nabble.com.