Return-Path: Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: (qmail 9421 invoked from network); 22 May 2009 14:35:06 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 22 May 2009 14:35:06 -0000 Received: (qmail 14501 invoked by uid 500); 22 May 2009 14:35:19 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 14483 invoked by uid 500); 22 May 2009 14:35:19 -0000 Mailing-List: contact issues-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list issues@cxf.apache.org Received: (qmail 14473 invoked by uid 99); 22 May 2009 14:35:19 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 22 May 2009 14:35:19 +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; Fri, 22 May 2009 14:35:07 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id E3D0B29A0015 for ; Fri, 22 May 2009 07:34:45 -0700 (PDT) Message-ID: <2070747346.1243002885932.JavaMail.jira@brutus> Date: Fri, 22 May 2009 07:34:45 -0700 (PDT) From: "Sergey Beryozkin (JIRA)" To: issues@cxf.apache.org Subject: [jira] Resolved: (CXF-2046) Response entity is enclosed in "Result" tags for classes implementing ExceptionMapper In-Reply-To: <1711957728.1234870619501.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/CXF-2046?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Sergey Beryozkin resolved CXF-2046. ----------------------------------- Resolution: Cannot Reproduce Fix Version/s: 2.2 Hi Gabo - I'm closing this JIRA for now as I can't see a bogus Result tag appearing. Feel free to reopen please if you can still see with 2.2.1 or later, ideally with a test case attached :-) cheers, Sergey > Response entity is enclosed in "Result" tags for classes implementing ExceptionMapper > ------------------------------------------------------------------------------------- > > Key: CXF-2046 > URL: https://issues.apache.org/jira/browse/CXF-2046 > Project: CXF > Issue Type: Bug > Components: REST > Affects Versions: 2.2 > Environment: Java 1.5 > Jetty 6.1 > Reporter: Gabo Manuel > Fix For: 2.2 > > > Environment and objects involved is the same as that in another issue: https://issues.apache.org/jira/browse/CXF-2045 > Additional objects involved: > public class RuntimeExceptionMapper implements ExceptionMapper{ > private static Logger logger = Logger.getLogger(RuntimeExceptionMapper.class); > public Response toResponse(RuntimeException fault) { > StringBuffer sb = new StringBuffer(); > sb.append("Generate some custom message to hide the real problem from end user."); > > ResponseBuilder rb = Response.status(500); > rb.type(MediaType.TEXT_PLAIN_TYPE); > rb.entity(sb.toString()); > logger.fatal(fault); > > Response resp = rb.build(); > > logger.info("entity: " + resp.getEntity().toString()); > > return resp; > } > } > Logs captured by TCPMon > HTTP/1.1 500 Internal Server Error > Content-Type: text/plain > Content-Length: 69 > Server: Jetty(6.1.11) > Generate some custom message to hide the real problem from end user. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.