Return-Path: Delivered-To: apmail-ws-sandesha-dev-archive@www.apache.org Received: (qmail 34111 invoked from network); 3 May 2010 18:04:18 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 3 May 2010 18:04:18 -0000 Received: (qmail 4442 invoked by uid 500); 3 May 2010 18:04:17 -0000 Delivered-To: apmail-ws-sandesha-dev-archive@ws.apache.org Received: (qmail 4273 invoked by uid 500); 3 May 2010 18:04:17 -0000 Mailing-List: contact java-dev-help@axis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@axis.apache.org Delivered-To: mailing list java-dev@axis.apache.org Received: (qmail 4265 invoked by uid 99); 3 May 2010 18:04:17 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 03 May 2010 18:04:17 +0000 X-ASF-Spam-Status: No, hits=-1380.8 required=10.0 tests=ALL_TRUSTED,AWL X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 03 May 2010 18:04:16 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o43I3t47029555 for ; Mon, 3 May 2010 18:03:56 GMT Message-ID: <28164016.17811272909835811.JavaMail.jira@thor> Date: Mon, 3 May 2010 14:03:55 -0400 (EDT) From: "Rich Scheuerle (JIRA)" To: java-dev@axis.apache.org Subject: [jira] Created: (AXIS2-4700) JAX-WS: Wrapper defaulting is wrong MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 JAX-WS: Wrapper defaulting is wrong ----------------------------------- Key: AXIS2-4700 URL: https://issues.apache.org/jira/browse/AXIS2-4700 Project: Axis2 Issue Type: Bug Components: jaxws Reporter: Rich Scheuerle Assignee: Rich Scheuerle A JAX-WS Web service client or provider may receive an UnmarshalException "unexpected element" error when it receives an inbound message. The error indicates that a problem has occurred converting the incoming message into the customer's JAXB data object. Here is an example message: Cause:javax.xml.bind.UnmarshalException - with linked exception: [javax.xml.bind.UnmarshalException: unexpected element (uri:"http://my.test/", local:"myOperation"). Expected elements are <{http://my.test/}myOperationResponse>] All of the following must be true for this error to occur: A) The JAX-WS Web service must use the document/literal wrapped style. B) The method being invoked must not have the @RequestWrapper or @ResponseWrapper annotation. C) The customer has provided a wrapper bean in the expected package (i.e. my.test.jaxws.MyOperationResponse). D) The customer has provided another (non-wrapper bean) in the same package as the Web service interface (i.e. my.test.MyOperationResponse) Solution: When a JAX-WS Web service method does not have the @RequestWrapper or @ResponseWrapper annotation, the JAX-WS project uses an algorithm to locate the wrapper classes. The algorithm should first look in a sub-package named "jaxws" for the wrapper bean. If the wrapper bean is not found, then it should look in the package associated with the target namespace. The error occurred because the algorithm was examining the packages in the wrong order. I am making a correction, and will commit code later today. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org For additional commands, e-mail: java-dev-help@axis.apache.org