[ https://issues.apache.org/jira/browse/CXF-1950?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Chris McClelland updated CXF-1950: ---------------------------------- Attachment: y.wsdl > wsdl2java omits @WebParam's header=true where <wsdl:service> element is > missing. > -------------------------------------------------------------------------------- > > Key: CXF-1950 > URL: https://issues.apache.org/jira/browse/CXF-1950 > Project: CXF > Issue Type: Bug > Components: Tooling > Affects Versions: 2.1.4 > Reporter: Chris McClelland > Priority: Minor > Attachments: y.wsdl > > > If you generate code from the WSDL below (a slightly modified version of a > WSDL retrieved from a running CXF service) using WSDLToJava, it fails to > generate the header=true properties on the @WebParam annotations. The weird > thing is that if you reinstate the <wsdl:service> element, the header=true > property is correctly generated. > bash-2.05b$ cd apache-cxf-2.1.4-SNAPSHOT/lib > bash-2.05b$ cat > y.wsdl <<EOF > > <?xml version="1.0" encoding="UTF-8"?> > > <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" > > xmlns:ns1="http://schemas.xmlsoap.org/soap/http" > > xmlns:ns2="http://xml.ms.com/ns/eai/string-tcp" > > xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" > > xmlns:tns="http://xml.ms.com/ns/msjava/greeter" > > xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="GreeterService" > > targetNamespace="http://xml.ms.com/ns/msjava/greeter"> > > <wsdl:types> > > <xsd:schema attributeFormDefault="unqualified" > > elementFormDefault="qualified" > > targetNamespace="http://xml.ms.com/ns/msjava/greeter" > > xmlns:tns="http://xml.ms.com/ns/msjava/greeter" > > xmlns:xsd="http://www.w3.org/2001/XMLSchema"> > > <xsd:element name="Blah" nillable="true" type="xsd:string"/> > > <xsd:element name="GreeterException" type="tns:GreeterException"/> > > <xsd:complexType name="GreeterException"> > > <xsd:sequence/> > > </xsd:complexType> > > <xsd:element name="Greeter" nillable="true" type="xsd:string"/> > > <xsd:element name="GreeterResponse" nillable="true" > > type="xsd:string"/> > > </xsd:schema> > > </wsdl:types> > > <wsdl:message name="GreeterException"> > > <wsdl:part element="tns:GreeterException" name="GreeterException"/> > > </wsdl:message> > > <wsdl:message name="GreeterResponse"> > > <wsdl:part element="tns:GreeterResponse" name="GreeterResponse"/> > > </wsdl:message> > > <wsdl:message name="Greeter"> > > <wsdl:part element="tns:Greeter" name="Greeter"/> > > <wsdl:part element="tns:Blah" name="Blah"/> > > </wsdl:message> > > <wsdl:portType name="Greeter"> > > <wsdl:operation name="Greeter"> > > <wsdl:input message="tns:Greeter" name="Greeter"/> > > <wsdl:output message="tns:GreeterResponse" name="GreeterResponse"/> > > <wsdl:fault message="tns:GreeterException" name="GreeterException"/> > > </wsdl:operation> > > </wsdl:portType> > > <wsdl:binding name="GreeterServiceSoapHttpBinding" type="tns:Greeter"> > > <soap:binding style="document" > > transport="http://schemas.xmlsoap.org/soap/http"/> > > <wsdl:operation name="Greeter"> > > <soap:operation soapAction="" style="document"/> > > <wsdl:input name="Greeter"> > > <soap:header message="tns:Greeter" part="Blah" use="literal"/> > > <soap:body parts="Greeter" use="literal"/> > > </wsdl:input> > > <wsdl:output name="GreeterResponse"> > > <soap:body use="literal"/> > > </wsdl:output> > > <wsdl:fault name="GreeterException"> > > <soap:fault name="GreeterException" use="literal"/> > > </wsdl:fault> > > </wsdl:operation> > > </wsdl:binding> > > <!--wsdl:service name="GreeterService"> > > <wsdl:port binding="tns:GreeterServiceSoapHttpBinding" > > name="GreeterJettyHTTPPort"> > > <soap:address location="http://localhost:7650/Greeter"/> > > </wsdl:port> > > </wsdl:service--> > > </wsdl:definitions> > > EOF > bash-2.05b$ java -classpath $(find . -name "*.jar" | tr '\n' ':'). > org.apache.cxf.tools.wsdlto.WSDLToJava y.wsdl > Dec 18, 2008 5:08:45 PM > org.apache.cxf.tools.validator.internal.WSDLRefValidator > collectValidationPoints > WARNING: WSDL document > file:/a/lnn16f2/vol/lnn16f2v1/cs_msjava_build/mcclellc/apache-cxf-2.1.4-SNAPSHOT/lib/y.wsdl > does not define any services > bash-2.05b$ grep WebParam com/ms/xml/ns/msjava/greeter/Greeter.java > import javax.jws.WebParam; > @WebParam(partName = "Greeter", name = "Greeter", targetNamespace = > "http://xml.ms.com/ns/msjava/greeter") > @WebParam(partName = "Blah", name = "Blah", targetNamespace = > "http://xml.ms.com/ns/msjava/greeter") -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.