Return-Path: Delivered-To: apmail-cxf-commits-archive@www.apache.org Received: (qmail 61536 invoked from network); 7 May 2010 14:57:52 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 7 May 2010 14:57:52 -0000 Received: (qmail 32633 invoked by uid 500); 7 May 2010 14:57:51 -0000 Delivered-To: apmail-cxf-commits-archive@cxf.apache.org Received: (qmail 32561 invoked by uid 500); 7 May 2010 14:57:51 -0000 Mailing-List: contact commits-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 commits@cxf.apache.org Received: (qmail 32554 invoked by uid 99); 7 May 2010 14:57:51 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 07 May 2010 14:57:51 +0000 X-ASF-Spam-Status: No, hits=-1188.6 required=10.0 tests=ALL_TRUSTED,AWL X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 07 May 2010 14:57:50 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 0CF3C23889D5; Fri, 7 May 2010 14:57:01 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r942091 - in /cxf/branches/2.2.x-fixes: ./ rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerFaultInInterceptor.java Date: Fri, 07 May 2010 14:57:01 -0000 To: commits@cxf.apache.org From: dkulp@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20100507145701.0CF3C23889D5@eris.apache.org> Author: dkulp Date: Fri May 7 14:57:00 2010 New Revision: 942091 URL: http://svn.apache.org/viewvc?rev=942091&view=rev Log: Merged revisions 942081 via svnmerge from https://svn.apache.org/repos/asf/cxf/trunk ........ r942081 | dkulp | 2010-05-07 10:23:40 -0400 (Fri, 07 May 2010) | 1 line Work around an J2EE TCK regression ........ Modified: cxf/branches/2.2.x-fixes/ (props changed) cxf/branches/2.2.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerFaultInInterceptor.java Propchange: cxf/branches/2.2.x-fixes/ ('svn:mergeinfo' removed) Propchange: cxf/branches/2.2.x-fixes/ ------------------------------------------------------------------------------ Binary property 'svnmerge-integrated' - no diff available. Modified: cxf/branches/2.2.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerFaultInInterceptor.java URL: http://svn.apache.org/viewvc/cxf/branches/2.2.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerFaultInInterceptor.java?rev=942091&r1=942090&r2=942091&view=diff ============================================================================== --- cxf/branches/2.2.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerFaultInInterceptor.java (original) +++ cxf/branches/2.2.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerFaultInInterceptor.java Fri May 7 14:57:00 2010 @@ -34,6 +34,7 @@ import javax.xml.ws.handler.Handler; import javax.xml.ws.handler.MessageContext; import javax.xml.ws.handler.soap.SOAPHandler; +import org.apache.cxf.binding.soap.HeaderUtil; import org.apache.cxf.binding.soap.SoapMessage; import org.apache.cxf.binding.soap.interceptor.SoapInterceptor; import org.apache.cxf.helpers.CastUtils; @@ -77,6 +78,7 @@ public class SOAPHandlerFaultInIntercept return; } + checkUnderstoodHeaders(message); MessageContext context = createProtocolMessageContext(message); HandlerChainInvoker invoker = getInvoker(message); invoker.setProtocolMessageContext(context); @@ -93,6 +95,18 @@ public class SOAPHandlerFaultInIntercept } + private void checkUnderstoodHeaders(SoapMessage soapMessage) { + Set paramHeaders = HeaderUtil.getHeaderQNameInOperationParam(soapMessage); + if (soapMessage.getHeaders().isEmpty() && paramHeaders.isEmpty()) { + //the TCK expects the getHeaders method to always be + //called. If there aren't any headers in the message, + //THe MustUnderstandInterceptor quickly returns without + //trying to calculate the understood headers. Thus, + //we need to call it here. + getUnderstoodHeaders(); + } + } + private void handleAbort(SoapMessage message, MessageContext context) { if (isRequestor(message)) {