Return-Path: Delivered-To: apmail-cxf-dev-archive@www.apache.org Received: (qmail 28436 invoked from network); 15 Nov 2010 16:57:41 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 15 Nov 2010 16:57:41 -0000 Received: (qmail 57424 invoked by uid 500); 15 Nov 2010 16:58:13 -0000 Delivered-To: apmail-cxf-dev-archive@cxf.apache.org Received: (qmail 57362 invoked by uid 500); 15 Nov 2010 16:58:13 -0000 Mailing-List: contact dev-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 dev@cxf.apache.org Received: (qmail 57354 invoked by uid 99); 15 Nov 2010 16:58:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Nov 2010 16:58:13 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [131.239.30.132] (HELO ntmamx2.progress.com) (131.239.30.132) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Nov 2010 16:58:05 +0000 Received: from ntmamx2.progress.com (127.0.0.1) by ntmamx2.progress.com (MlfMTA v3.2r9) id hs5j9i0171sr for ; Mon, 15 Nov 2010 11:57:20 -0500 (envelope-from ) Received: from progress.com ([172.16.3.168]) by ntmamx2.progress.com (SonicWALL 7.2.3.3283) with ESMTP (AIO); Mon, 15 Nov 2010 11:57:20 -0500 Received: from NTMAEXCAS01.bedford.progress.com (ntmaexcas01 [10.128.13.35]) by progress.com (8.13.8/8.13.8) with ESMTP id oAFGvOEd011515 for ; Mon, 15 Nov 2010 11:57:24 -0500 (EST) Received: from pscmail02.bedford.progress.com ([fe80::8806:e130:2890:161b]) by NTMAEXCAS01.bedford.progress.com ([::1]) with mapi; Mon, 15 Nov 2010 11:57:24 -0500 From: Seumas Soltysik To: "dev@cxf.apache.org" Date: Mon, 15 Nov 2010 11:57:24 -0500 Subject: Issue with SoapTransportFactory Thread-Topic: Issue with SoapTransportFactory Thread-Index: AQHLhOYslO4mAbxWc0O7GuNO8GCAnA== Message-ID: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US x-ems-proccessed: +CmIlJ+kdV7Z341JADFd9w== x-ems-stamp: zXtaVz8v+nQQ1M36ZfkePQ== Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mlf-Version: 7.2.3.3283 X-Mlf-UniqueId: o201011151657200288377 X-Virus-Checked: Checked by ClamAV on apache.org SoapTransportFactory extends AbstractTransportFactory which contains a prot= ected Bus data member. However, SoapTransportFactory has its own private Bu= s data member and does not make use of the Bus data member inherited from A= bstractTransportFactory. Why is this? Is this done on purpose or is this an= oversight? public class SoapTransportFactory extends AbstractTransportFactory implemen= ts DestinationFactory, WSDLEndpointFactory, ConduitInitiator { =20 private Bus bus; } public abstract class AbstractTransportFactory { protected Bus bus; } In a testcase that I am developing this has led to problems. If I initializ= e an instance of SoapTransportFactory using the cxf-extension-soap.xml conf= iguration, setTransportIDs() is called on the base class AbstractTransport= Factory which ultimately calls register() which registers the transport IDs= with the bus: public final void register() { if (null =3D=3D bus) { return; } if (this instanceof DestinationFactory) { DestinationFactoryManager dfm =3D bus.getExtension(DestinationF= actoryManager.class); if (null !=3D dfm && getTransportIds() !=3D null) { for (String ns : getTransportIds()) { dfm.registerDestinationFactory(ns, (DestinationFactory)= this); } } } However, because AbstractTransportFactory has its own Bus instance, which i= s not initialized and therefore null, the transport IDs are never registere= d with the Bus instance that is visible to the SoapTransportFactory. I thin= k this issue has been disguised by the fact that usually SoapTransportFacto= ry is not initialized without initializing other transport factories which = do the right thing registering namespaces with the Bus.