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 7E57310B94 for ; Thu, 20 Mar 2014 20:49:52 +0000 (UTC) Received: (qmail 24795 invoked by uid 500); 20 Mar 2014 20:49:49 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 24635 invoked by uid 500); 20 Mar 2014 20:49:48 -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 24559 invoked by uid 99); 20 Mar 2014 20:49:47 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 20 Mar 2014 20:49:47 +0000 Date: Thu, 20 Mar 2014 20:49:47 +0000 (UTC) From: "Daniel Kulp (JIRA)" To: issues@cxf.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Resolved] (CXF-5629) In robust one-way fault the fault message is written twice 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-5629?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Daniel Kulp resolved CXF-5629. ------------------------------ Resolution: Fixed Fix Version/s: 2.7.11 3.0.0 Assignee: Daniel Kulp > In robust one-way fault the fault message is written twice > ---------------------------------------------------------- > > Key: CXF-5629 > URL: https://issues.apache.org/jira/browse/CXF-5629 > Project: CXF > Issue Type: Bug > Affects Versions: 3.0.0 > Reporter: Grzegorz Grzybek > Assignee: Daniel Kulp > Fix For: 3.0.0, 2.7.11 > > Attachments: CXF-5629-2.7.x.patch, CXF-5629.patch > > > I have robust one-way operation. However the resulting soap fault is not written to response, because the output stream is closed, as the same {{faultObserver}} is called twice: > 1. in {{org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(Message)}}: > {code:java} > boolean isOneWay = false; > if (message.getExchange() != null) { > if (message.getContent(Exception.class) != null) { > message.getExchange().put(Exception.class, ex2); > } > isOneWay = message.getExchange().isOneWay() > && !MessageUtils.isTrue(message.getContextualProperty(Message.ROBUST_ONEWAY)); > } > if (faultObserver != null && !isOneWay) { > faultObserver.onMessage(message); > } > {code} > 2. later in {{org.apache.cxf.interceptor.OneWayProcessorInterceptor.handleMessage(Message)}}: > {code:java} > if (message.getContent(Exception.class) != null) { > // return the fault over the response fault channel > MessageObserver faultObserver = chain.getFaultObserver(); > if (faultObserver != null) { > message.getExchange().setOneWay(false); > faultObserver.onMessage(message); > } > return; > } > {code} > However, exchage is one-way only in second call, but the soap fault has no change to get to client (output stream is closed). > I'm working on a patch -- This message was sent by Atlassian JIRA (v6.2#6252)