Return-Path: Delivered-To: apmail-servicemix-dev-archive@www.apache.org Received: (qmail 11086 invoked from network); 2 Nov 2009 21:06:16 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 2 Nov 2009 21:06:16 -0000 Received: (qmail 9107 invoked by uid 500); 2 Nov 2009 21:06:15 -0000 Delivered-To: apmail-servicemix-dev-archive@servicemix.apache.org Received: (qmail 9044 invoked by uid 500); 2 Nov 2009 21:06:15 -0000 Mailing-List: contact dev-help@servicemix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@servicemix.apache.org Delivered-To: mailing list dev@servicemix.apache.org Received: (qmail 9034 invoked by uid 99); 2 Nov 2009 21:06:15 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 Nov 2009 21:06:15 +0000 X-ASF-Spam-Status: No, hits=-10.5 required=5.0 tests=AWL,BAYES_00,NORMAL_HTTP_TO_IP,RCVD_IN_DNSWL_HI,WEIRD_PORT X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 Nov 2009 21:06:13 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id D5B9C234C052 for ; Mon, 2 Nov 2009 13:05:52 -0800 (PST) Message-ID: <2111475827.1257195952852.JavaMail.jira@brutus> Date: Mon, 2 Nov 2009 13:05:52 -0800 (PST) From: "Paul Mietz Egli (JIRA)" To: dev@servicemix.apache.org Subject: [jira] Commented: (SMX4-417) calling with expression can delete message and headers In-Reply-To: <621476460.1257195112744.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: ae95407df07c98740808b2ef9da0087c [ https://issues.apache.org/activemq/browse/SMX4-417?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=55127#action_55127 ] Paul Mietz Egli commented on SMX4-417: -------------------------------------- Steps to reproduce: 1. Unpack apache-servicemix-4.0.0.tar.gz. 2. Start ServiceMix and run "features/install camel-jetty" and "features/install camel-groovy". 3. Build the attached project and copy the JAR file to $SERVICEMIX_HOME/deploy 4. Tail the servicemix.log file to see the timer-initiated messages going by. 5. Trigger a message from jetty using "curl http://localhost:8103/?application=TEST". Observation: message headers are lost for jetty but retained for timer. > calling with expression can delete message and headers > --------------------------------------------------------------------------- > > Key: SMX4-417 > URL: https://issues.apache.org/activemq/browse/SMX4-417 > Project: ServiceMix 4 > Issue Type: Bug > Affects Versions: 4.0.0 > Environment: OSX 10.6.1, Java(TM) SE Runtime Environment (build 1.6.0_15-b03-219) > Reporter: Paul Mietz Egli > Attachments: SMX4-417.tar.gz > > > I've got a route that takes an HTTP form post, does some transformations, and sends an email. One of the transforms I'd like to do is to set a header value based on the result of a Groovy expression. I found that setting a header with ... clears out the entire exchange. Setting a header using ... works fine. > Here's a route that I'm using to diagnose this problem: > > > > > > > > > > TEST > > > > > > > > "my header is ${in.headers.application}" > > > > > Messages that originate from the timer look fine: > 12:31:49,332 | INFO | mer?period=30000 | from timer | rg.apache.camel.processor.Logger 88 | Exchange[Id:ID-iago.local/53297-1257192385112/0-16, Properties:{org.apache.camel.timer.name=mytimer, org.apache.camel.timer.firedTime=Mon Nov 02 12:31:49 PST 2009, org.apache.camel.timer.period=30000}, Headers:{application=TEST, firedTime=Mon Nov 02 12:31:49 PST 2009}, BodyType:null, Body:null, Out: null] > 12:31:49,335 | INFO | ansform thread:3 | after set header | rg.apache.camel.processor.Logger 88 | Exchange[Id:ID-iago.local/53297-1257192385112/0-17, Properties:{org.apache.camel.timer.name=mytimer, org.apache.camel.timer.firedTime=Mon Nov 02 12:31:49 PST 2009, org.apache.camel.timer.period=30000}, Headers:{application=TEST, fromGroovy=my header is TEST, firedTime=Mon Nov 02 12:31:49 PST 2009}, BodyType:null, Body:null, Out: null] > Messages that originate in response to a request to http://localhost:8103/?application=TEST appear to be lost after the header is set with the tag: > 12:32:03,607 | INFO | 34102763@qtp13-1 | from jetty | rg.apache.camel.processor.Logger 88 | Exchange[Id:ID-iago.local/53297-1257192385112/0-18, Properties:{}, Headers:{application=TEST, Host=localhost:8103, org.apache.camel.component.http.query=application=TEST, User-Agent=curl/7.19.0 (i386-apple-darwin9.7.0) libcurl/7.19.0 zlib/1.2.3, http.requestMethod=GET, Accept=*/*}, BodyType:org.apache.camel.converter.stream.StreamCacheConverter.InputStreamCache, Body:, Out: null] > 12:32:03,611 | INFO | ansform thread:3 | after set header | rg.apache.camel.processor.Logger 88 | Exchange[Id:ID-iago.local/53297-1257192385112/0-19, Properties:{}, Headers:{}, BodyType:null, Body:null, Out: null] > The message after the is completely blank. I've tried building the route with the Java DSL but it does the same thing. Anything added after the ... element is added to the message, but all previous contents were lost. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.