Return-Path: Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: (qmail 89498 invoked from network); 3 Feb 2009 18:52:31 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 3 Feb 2009 18:52:31 -0000 Received: (qmail 58337 invoked by uid 500); 3 Feb 2009 18:52:31 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 58323 invoked by uid 500); 3 Feb 2009 18:52:31 -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 58311 invoked by uid 99); 3 Feb 2009 18:52:31 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Feb 2009 10:52:31 -0800 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; Tue, 03 Feb 2009 18:52:21 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id E6737234C4B6 for ; Tue, 3 Feb 2009 10:51:59 -0800 (PST) Message-ID: <1205253943.1233687119942.JavaMail.jira@brutus> Date: Tue, 3 Feb 2009 10:51:59 -0800 (PST) From: "Yunfeng Fei (JIRA)" To: issues@cxf.apache.org Subject: [jira] Created: (CXF-2021) SOAPFault detail is not set in WebServiceException/SOAPFaultException that is thrown from dispatch.invoke MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org SOAPFault detail is not set in WebServiceException/SOAPFaultException that is thrown from dispatch.invoke --------------------------------------------------------------------------------------------------------- Key: CXF-2021 URL: https://issues.apache.org/jira/browse/CXF-2021 Project: CXF Issue Type: Bug Components: JAX-WS Runtime Affects Versions: 2.1.3 Environment: Windows XP, Jdk 1.5, tomacat 5.5. Reporter: Yunfeng Fei I'm using the dispatch mechanism to invoke a soap service in message mode. Upon catching the WebServiceException thrown by the dispatch.invoke method, i try to extract the soap fault information from it (if it is a SOAPFaultException). That's when i realized the SOAPFault detail is missing (is null). The code i'm using is shown below. Also shown is the returned soap fault with detail when the same service is called using SOAPUI. It appears the SOAPFault detail is not set when it is wrapped into a SOAPFaultException and thrown as a WebServiceException. //It appears that the JAX-WS implementation in //cxf simply does not set the optional SOAPFault Detail object //in the SOAPFault object wrapped by the SOAPFaultException private SOAPMessage createFaultMessageFromWebServiceException(WebServiceException wse) throws SOAPException { SOAPMessage msg = getNewSOAPMessage(); if (wse instanceof SOAPFaultException) { SOAPFault fault = ((SOAPFaultException) wse).getFault(); //fault.hasDetail() return false msg.getSOAPBody().addFault(fault.getFaultCodeAsQName(), fault.getFaultString()); } else { msg.getSOAPBody().addFault().setFaultString(wse.getMessage()); } return msg; } The same service invoked through SOAPUI returns SOAPFault message with detail. soap:Server Fault occurred while processing. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.