It's possible that the modified schema is causing issues.   What's the stack 
trace if you run wsdl2java with -v?

Also, you can try adding: -noAddressBinding to wsdl2java to turn off the 
internal mapping of the ws-addressing schema into javax.xml.ws.wsaddressing 
types.   It would actually generate types for stuff in the schema which may or 
may not be appropriate for what you need to accomplish, but worth a shot.

That said, using a catalog or something to map that schemaLocation to a local 
xsd is probably the best option.

Dan



On Tue October 27 2009 9:19:43 am Nate Woody wrote:
> I maintain a CXF-interface to Microsofts HPC2008 webservice (meaning the
> WSDL exists in the wild), which we recently upgraded and I'm unable to
> build stubs off of the WSDL anymore.  I've tried wsdltojava from 2.3 and
> 2.4, but I get the same error.   It's a WS-Addressing error of some
> sort, but I'm not sure if it's a CXF bug.  The WSDL provides an import
> for WS-A:
> 
>                   <xsd:import
> 
>                         schemaLocation="http://hostname/WSDL?xsd=xsd5";
> 
>                         namespace="http://www.w3.org/2005/08/addressing";
> />
> 
> 
> 
> Which refers to a partial schema I've pasted at the bottom of the email.
> If I change that import to point to a local ws-addr.xsd taken from the
> W3 site then the service builds and works OK.  The provided schema is
> missing these entries, which I suspect is what breaks things.
> 
> 
> 
>   <xs:element name="ReplyTo" type="tns:EndpointReferenceType"/>
> 
>   <xs:element name="From" type="tns:EndpointReferenceType"/>
> 
>   <xs:element name="FaultTo" type="tns:EndpointReferenceType"/>
> 
>   <xs:element name="To" type="tns:AttributedURIType"/>
> 
>   <xs:element name="Action" type="tns:AttributedURIType"/>
> 
> 
> 
> I can provide a test case and put in a JIRA ticket if the dev's think
> this is a CXF bug.
> 
> 
> 
> Thanks,
> 
> Nate
> 
> 
> 
> 
> 
> Partial WS-A schema:
> 
> 
> 
> <xs:schema elementFormDefault="qualified"
> targetNamespace="http://www.w3.org/2005/08/addressing";>
> 
> <xs:complexType name="EndpointReferenceType">
> 
> <xs:sequence>
> 
> <xs:element minOccurs="0" maxOccurs="1" name="Address"
> type="tns:AttributedURIType"/>
> 
> <xs:element minOccurs="0" maxOccurs="1" name="ReferenceParameters"
> type="tns:ReferenceParametersType"/>
> 
> <xs:element minOccurs="0" maxOccurs="1" name="Metadata"
> type="tns:MetadataType"/>
> 
> <xs:any minOccurs="0" maxOccurs="unbounded" namespace="##other"/>
> 
> </xs:sequence>
> 
> <xs:anyAttribute/>
> 
> </xs:complexType>
> 
> <xs:complexType name="AttributedURIType">
> 
> <xs:simpleContent>
> 
> <xs:extension base="xs:anyURI">
> 
> <xs:anyAttribute/>
> 
> </xs:extension>
> 
> </xs:simpleContent>
> 
> </xs:complexType>
> 
> <xs:complexType name="ReferenceParametersType">
> 
> <xs:sequence>
> 
> <xs:any minOccurs="0" maxOccurs="unbounded"/>
> 
> </xs:sequence>
> 
> <xs:anyAttribute/>
> 
> </xs:complexType>
> 
> <xs:complexType name="MetadataType">
> 
> <xs:sequence>
> 
> <xs:any minOccurs="0" maxOccurs="unbounded"/>
> 
> </xs:sequence>
> 
> <xs:anyAttribute/>
> 
> </xs:complexType>
> 
> </xs:schema>
> 

-- 
Daniel Kulp
[email protected]
http://www.dankulp.com/blog

Reply via email to