Return-Path: Delivered-To: apmail-camel-dev-archive@www.apache.org Received: (qmail 46100 invoked from network); 4 Mar 2010 08:30:21 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 4 Mar 2010 08:30:21 -0000 Received: (qmail 34620 invoked by uid 500); 4 Mar 2010 08:30:12 -0000 Delivered-To: apmail-camel-dev-archive@camel.apache.org Received: (qmail 34579 invoked by uid 500); 4 Mar 2010 08:30:11 -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 34571 invoked by uid 500); 4 Mar 2010 08:30:11 -0000 Delivered-To: apmail-activemq-camel-dev@activemq.apache.org Received: (qmail 34568 invoked by uid 99); 4 Mar 2010 08:30:11 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 04 Mar 2010 08:30:11 +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:30:04 +0000 Received: from brutus.apache.org (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id AD637234C4C9 for ; Thu, 4 Mar 2010 08:29:44 +0000 (UTC) Message-ID: <874292508.5311267691384694.JavaMail.jira@brutus.apache.org> Date: Thu, 4 Mar 2010 08:29:44 +0000 (UTC) From: "Claus Ibsen (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 [ https://issues.apache.org/activemq/browse/CAMEL-2519?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=58021#action_58021 ] Claus Ibsen commented on CAMEL-2519: ------------------------------------ And since this is a new feature I would rather -1 it to avoid that big problem above ^^^. The end user can just use a custom {{HttpBinding}} to implement his own logic as he also did. > 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.