This discussion is archived
1 Reply Latest reply: Oct 11, 2012 8:59 AM by 669114 RSS

Problem in client generation from wsdl file

928695 Newbie
Currently Being Moderated
Hi i am trying to generate client from a wsdl file through apache cxf framework, but it throws WSDLRefValidator error.
Here is the error statment:

Oct 11, 2012 11:51:33 AM org.apache.cxf.tools.validator.internal.WSDLRefValidator collectValidationPoints
WARNING: WSDL document file:/D:/latestWS20120925/WebServiceTest26092012/WebContent/wsdl/PlmWebserviceImportGcas.wsdl does not define any services

WSDLToJava Error:
line 5 column 646 of file:/D:/latestWS20120925/WebServiceTest26092012/WebContent/wsdl/PlmWebserviceImportGcas.wsdl: cvc-complex-type.2.4.a: Invalid content was found starting with element 'WL5G3N0:definitions'. One of '{"http://www.w3.org/2001/XMLSchema":include, "http://www.w3.org/2001/XMLSchema":import, "http://www.w3.org/2001/XMLSchema":redefine, "http://www.w3.org/2001/XMLSchema":annotation, "http://www.w3.org/2001/XMLSchema":simpleType, "http://www.w3.org/2001/XMLSchema":complexType, "http://www.w3.org/2001/XMLSchema":group, "http://www.w3.org/2001/XMLSchema":attributeGroup, "http://www.w3.org/2001/XMLSchema":element, "http://www.w3.org/2001/XMLSchema":attribute, "http://www.w3.org/2001/XMLSchema":notation}' is expected.

org.apache.cxf.tools.common.ToolException:
line 5 column 646 of file:/D:/latestWS20120925/WebServiceTest26092012/WebContent/wsdl/PlmWebserviceImportGcas.wsdl: cvc-complex-type.2.4.a: Invalid content was found starting with element 'WL5G3N0:definitions'. One of '{"http://www.w3.org/2001/XMLSchema":include, "http://www.w3.org/2001/XMLSchema":import, "http://www.w3.org/2001/XMLSchema":redefine, "http://www.w3.org/2001/XMLSchema":annotation, "http://www.w3.org/2001/XMLSchema":simpleType, "http://www.w3.org/2001/XMLSchema":complexType, "http://www.w3.org/2001/XMLSchema":group, "http://www.w3.org/2001/XMLSchema":attributeGroup, "http://www.w3.org/2001/XMLSchema":element, "http://www.w3.org/2001/XMLSchema":attribute, "http://www.w3.org/2001/XMLSchema":notation}' is expected.
     at org.apache.cxf.tools.validator.internal.SchemaValidator.validate(SchemaValidator.java:203)
     at org.apache.cxf.tools.validator.internal.SchemaValidator.validate(SchemaValidator.java:119)
     at org.apache.cxf.tools.validator.internal.SchemaValidator.isValid(SchemaValidator.java:103)
     at org.apache.cxf.tools.validator.internal.WSDL11Validator.isValid(WSDL11Validator.java:157)
     at org.apache.cxf.tools.wsdlto.frontend.jaxws.wsdl11.JAXWSDefinitionBuilder.validate(JAXWSDefinitionBuilder.java:204)
     at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.processWsdl(WSDLToJavaContainer.java:182)
     at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:142)
     at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:300)


The excerpt from wsdl file is provided below:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" name="PlmWebserviceImportGcas.wsdl" targetNamespace="D:/webservice">
<wsdl:types>
<xsd:schema xmlns="http://www.pg.com/css/webservice" xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="http://www.pg.com/css/webservice">
*<WL5G3N0:definitions xmlns="" xmlns:WL5G3N0="http://schemas.xmlsoap.org/wsdl/" xmlns:WL5G3N1="http://www.pg.com/Inputs/HubPollForTSStatusInput" xmlns:WL5G3N2="http://www.pg.com/Outputs/HubPollForTSStatusOutput" xmlns:WL5G3N3="http:/www.pg.com/productNet/HubSubmitForumlatoCSSInput" xmlns:WL5G3N4="http:/www.pg.com/productNet/HubSubmitForumlatoCSSOutput" xmlns:WL5G3N5="http://www.pg.com/Inputs/HubDeleteTSRequestInput" xmlns:WL5G3N6="http://www.pg.com/Outputs/HubDeleteTSRequestOutput" xmlns:WL5G3N7="http://www.pg.com/WS/FormulaHubWS" xmlns:WL5G3N8="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="http://www.pg.com/WS/FormulaHubWS">*
                    
<WL5G3N0:types>
<xsd:schema xmlns="http:/www.pg.com/productNet/HubSubmitForumlatoCSSOutput" xmlns:CSS_SubmitFormulaOutput.xsd="http://pg.com/Inputs/CSS_SubmitFormulaOutput" xmlns:ns2="http://www.pg.com/Inputs/HubPollForTSStatusInput" xmlns:ns3="http://www.pg.com/Outputs/HubPollForTSStatusOutput" xmlns:ns4="http:/www.pg.com/productNet/HubSubmitForumlatoCSSInput" xmlns:ns5="http:/www.pg.com/productNet/HubSubmitForumlatoCSSOutput" xmlns:ns6="http://www.pg.com/Inputs/HubDeleteTSRequestInput" xmlns:ns7="http://www.pg.com/Outputs/HubDeleteTSRequestOutput" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://www.pg.com/WS/FormulaHubWS" attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http:/www.pg.com/productNet/HubSubmitForumlatoCSSOutput">
                              <xsd:import namespace="http://pg.com/Inputs/CSS_SubmitFormulaOutput"/>
                              <xsd:element name="SubmitFormulatoCSSOutput">
                                   <xsd:complexType>
                                        <xsd:sequence>
                                             <xsd:element ref="CSS_SubmitFormulaOutput.xsd:SubmitFormulatoCSS_Output"/>


It seems to be problem with tag WL5G3NO declaration.
Can anyone suggest how to rectify this?
Thanks

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points