Return-Path: X-Original-To: apmail-cxf-issues-archive@www.apache.org Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 884C0DD61 for ; Mon, 15 Oct 2012 15:10:03 +0000 (UTC) Received: (qmail 32008 invoked by uid 500); 15 Oct 2012 15:10:03 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 31934 invoked by uid 500); 15 Oct 2012 15:10:03 -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 31923 invoked by uid 99); 15 Oct 2012 15:10:03 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Oct 2012 15:10:03 +0000 Date: Mon, 15 Oct 2012 15:10:03 +0000 (UTC) From: "Yi Xiao (JIRA)" To: issues@cxf.apache.org Message-ID: <1544523794.45542.1350313803429.JavaMail.jiratomcat@arcas> In-Reply-To: <1166402024.45536.1350313563150.JavaMail.jiratomcat@arcas> Subject: [jira] [Updated] (CXF-4565) The message flow is not correct when handler throw ProtocolException outbound MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CXF-4565?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yi Xiao updated CXF-4565: ------------------------- Attachment: cxf-4565.patch Could some one review the patch? thank you very much :) > The message flow is not correct when handler throw ProtocolException outbound > ----------------------------------------------------------------------------- > > Key: CXF-4565 > URL: https://issues.apache.org/jira/browse/CXF-4565 > Project: CXF > Issue Type: Bug > Components: JAX-WS Runtime > Reporter: Yi Xiao > Labels: handler > Attachments: cxf-4565.patch > > > The scenario is using two SoapHandler and one LogicalHandler to intercept the message from client, and when LogicalHandler at server side handle the outbound message, it throws a ProtocolException. > Now, the message flow at server side in CXF is: > Server_SOAPHandler1_handleMessage_Inbound: > Server_SOAPHandler2_handleMessage_Inbound: > Server_LogicalHandler_handleMessage_Inbound: > Server_countString: > Server_LogicalHandler_handleMessage_Outbound: > Server_LogicalHandler_handleFault_Outbound: // All of the three > Server_SOAPHandler2_handleFault_Outbound: // handlerFault methods > Server_SOAPHandler1_handleFault_Outbound: // are invoked > Server_LogicalHandler_close: > Server_SOAPHandler2_close: > Server_SOAPHandler1_close: > But according to jsr224 9.3.2.1 > Throw ProtocolException or a subclass This indicates that normal message processing should cease. > Subsequent actions depend on whether the MEP in use requires a response to the message currently being processed or not: > No response Normal message processing stops, close is called on each previously invoked handler in the chain, the exception is dispatched (see section 9.1.2.3). > I also test the same case in WebSphere8.5 and Glassfish3.1.2.2, the message flow is: > Server_SOAPHandler1_handleMessage_Inbound: > Server_SOAPHandler2_handleMessage_Inbound: > Server_LogicalHandler_handleMessage_Inbound: > Server_countString: > Server_LogicalHandler_handleMessage_Outbound: > Server_LogicalHandler_close: > Server_SOAPHandler2_close: > Server_SOAPHandler1_close: > The handleFault methods are not called, and the close methods are called directly, I think it matches the spec better. > I also provide a patch for the issue. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira