Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 82039200B3C for ; Mon, 6 Jun 2016 17:43:23 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 806C5160A24; Mon, 6 Jun 2016 15:43:23 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id D15D0160A55 for ; Mon, 6 Jun 2016 17:43:22 +0200 (CEST) Received: (qmail 77443 invoked by uid 500); 6 Jun 2016 15:43:21 -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 77308 invoked by uid 99); 6 Jun 2016 15:43:21 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Jun 2016 15:43:21 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 011722C1F54 for ; Mon, 6 Jun 2016 15:43:21 +0000 (UTC) Date: Mon, 6 Jun 2016 15:43:21 +0000 (UTC) From: "Akitoshi Yoshida (JIRA)" To: issues@cxf.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Assigned] (CXF-6863) WS-RM 3.x does not work with attachments upon a network error MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Mon, 06 Jun 2016 15:43:23 -0000 [ https://issues.apache.org/jira/browse/CXF-6863?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Akitoshi Yoshida reassigned CXF-6863: ------------------------------------- Assignee: Akitoshi Yoshida > WS-RM 3.x does not work with attachments upon a network error > ------------------------------------------------------------- > > Key: CXF-6863 > URL: https://issues.apache.org/jira/browse/CXF-6863 > Project: CXF > Issue Type: Bug > Components: WS-* Components > Affects Versions: 3.1.3, 3.0.9 > Reporter: Akitoshi Yoshida > Assignee: Akitoshi Yoshida > Attachments: 0001-WS-RM-3.x-fix-for-retransmission-works-with-attachme.patch > > > When sending messages with an attachment, the CXF 3.x WS-RM code may lose message at the client side when a network error occurs. This was working with CXF 2.x WS-RM. > This problem is related to the change CXF-4866 which changed the way how the outgoing message is captured. Previously, the entire message was buffered and captured, which isolated this capturing from network issue. In 3.x, only the SOAP part is captured in this way and not the attachments. As a result, an exception will be thrown during the attachment serialization when a network error occurs and the message will not be correctly placed in the retransmission queue. > By comparing CXF 3.x and 2.x code, > In 3.x., AttachmentSerializer.writeProlog will directly writes to the IO and this can trigger a Fault from AttachmentOutInterceptor.handleMessage. > URLConnectionHTTPConduit$URLConnectionWrappedOutputStream(AbstractThresholdOutputStream).write(byte[], int, int) line: 61 > URLConnectionHTTPConduit$URLConnectionWrappedOutputStream(AbstractWrappedOutputStream).write(byte[]) line: 60 > CacheAndWriteOutputStream.write(byte[]) line: 89 > AttachmentSerializer.writeProlog() line: 182 > AttachmentOutInterceptor.handleMessage(Message) line: 77 > whereas in CXF 2.x, AttachmentSerializer.writeProlog will write to the buffered WriteOnCloseOutputStream, as its RetransmissionInterceptor inserts WriteOnCloseOutputStream to isolate itself from any network issue. > WriteOnCloseOutputStream(CachedOutputStream).write(byte[]) line: 466 > CacheAndWriteOutputStream.write(byte[]) line: 89 > AttachmentSerializer.writeProlog() line: 172 > AttachmentOutInterceptor.handleMessage(Message) line: 72 > CXF 2.x, RetransmissionInterceptor inserted WriteOnCloseOutputStream to capture the message entirely. > There seem to be other issues with attachments handling in CXF 3.x. Along with other issues CXF-6646, I am not sure how we should fix all these issues. -- This message was sent by Atlassian JIRA (v6.3.4#6332)