Return-Path: Delivered-To: apmail-camel-dev-archive@www.apache.org Received: (qmail 52556 invoked from network); 4 Mar 2010 08:44:23 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 4 Mar 2010 08:44:23 -0000 Received: (qmail 48766 invoked by uid 500); 4 Mar 2010 08:44:13 -0000 Delivered-To: apmail-camel-dev-archive@camel.apache.org Received: (qmail 48731 invoked by uid 500); 4 Mar 2010 08:44:13 -0000 Mailing-List: contact dev-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list dev@camel.apache.org Received: (qmail 48723 invoked by uid 500); 4 Mar 2010 08:44:13 -0000 Delivered-To: apmail-activemq-camel-dev@activemq.apache.org Received: (qmail 48720 invoked by uid 99); 4 Mar 2010 08:44:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 04 Mar 2010 08:44:13 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED 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; Thu, 04 Mar 2010 08:44:05 +0000 Received: from brutus.apache.org (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 871A0234C4C5 for ; Thu, 4 Mar 2010 08:43:44 +0000 (UTC) Message-ID: <609283113.5371267692224551.JavaMail.jira@brutus.apache.org> Date: Thu, 4 Mar 2010 08:43:44 +0000 (UTC) From: "Willem Jiang (JIRA)" To: camel-dev@activemq.apache.org Subject: [jira] Commented: (CAMEL-2519) camel-jetty - When returning an exception then allow to use custom http error code from Exchange.HTTP_RESPONSE_CODE In-Reply-To: <1700293769.3881267604984480.JavaMail.jira@brutus.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: ae95407df07c98740808b2ef9da0087c X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/activemq/browse/CAMEL-2519?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=58023#action_58023 ] Willem Jiang commented on CAMEL-2519: ------------------------------------- I agree we can't fix this side effect unless we introduce an HTTP header overrule mechanism and it will break the back ward compatibility. I will revert my patch of this issue. > camel-jetty - When returning an exception then allow to use custom http error code from Exchange.HTTP_RESPONSE_CODE > ------------------------------------------------------------------------------------------------------------------- > > Key: CAMEL-2519 > URL: https://issues.apache.org/activemq/browse/CAMEL-2519 > Project: Apache Camel > Issue Type: Improvement > Components: camel-jetty > Affects Versions: 2.2.0 > Reporter: Claus Ibsen > Assignee: Willem Jiang > Priority: Minor > Fix For: 2.3.0 > > > By default camel-jetty will use http error code 500. But end user may override and set a specific error code to use instead > See nabble: > http://old.nabble.com/Return-exception-message-in-HTTP-body-ts27757151.html > For example in DSL directly > {code} > onException(ValidationException).setHeader(Exchange.HTTP_RESPONSE_CODE, constant(HttpServletResponse.SC_BAD_REQUEST)); > {code} -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.