I have just been trying to generate a service and clients in VS2005
for the AccountService. The wsdl.exe tool successfully generated a
Service Interface and Client classes, but in the process threw a large
number of errors. Please see below. I was wondering what had caused
this and if there were any plans to fix these errors. I have not
written any code using these classes yet, I will post again when I do.
Generating serverInterface Class:
<pre>
Setting environment for using Microsoft Visual Studio 2005 x86 tools.
C:\Program Files\Microsoft Visual Studio 8\VC>wsdl /language:CS /
serverInterface
https://sandbox.google.com/api/adsense/v3/AccountService?wsdl Microsoft (R) Web Services Description Language Utility
[Microsoft (R) .NET Framework, Version 2.0.50727.42]
Copyright (C) Microsoft Corporation. All rights reserved.
Warning: This web reference does not conform to WS-I Basic Profile
v1.1.
R2028, R2029: A DESCRIPTION using the WSDL namespace and the WSDL SOAP
binding n
amespace MUST be valid according to the XML Schemas found at http://schemas.xmls oap.org/wsdl/2003-02-11.xsd and http://schemas.xmlsoap.org/wsdl/soap/2003-02-11.
xsd.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountServicePort
Type' is invalid according to its datatype 'http://www.w3.org/2001/ XMLSchema:NCN
ame' - The '/' character, hexadecimal value 0x2F, cannot be included
in a name.
Line 375, position 7299.
- Warning: The element 'operation' in namespace 'http://
schemas.xmlsoap.org/w
sdl/' has invalid child element 'fault' in namespace 'http://
schemas.xmlsoap.org
/wsdl/'. List of possible elements expected: 'output' in namespace
'http://schem as.xmlsoap.org/wsdl/'. Line 375, position 8100.
- Warning: The element 'operation' in namespace 'http://
schemas.xmlsoap.org/w
sdl/' has invalid child element 'fault' in namespace 'http://
schemas.xmlsoap.org
/wsdl/'. List of possible elements expected: 'output' in namespace
'http://schem as.xmlsoap.org/wsdl/'. Line 375, position 11087.
- Warning: The element 'operation' in namespace 'http://
schemas.xmlsoap.org/w
sdl/' has invalid child element 'fault' in namespace 'http://
schemas.xmlsoap.org
/wsdl/'. List of possible elements expected: 'output' in namespace
'http://schem as.xmlsoap.org/wsdl/'. Line 375, position 11394.
- Warning: The element 'operation' in namespace 'http://
schemas.xmlsoap.org/w
sdl/' has invalid child element 'fault' in namespace 'http://
schemas.xmlsoap.org
/wsdl/'. List of possible elements expected: 'output' in namespace
'http://schem as.xmlsoap.org/wsdl/'. Line 375, position 12970.
- Warning: The identity constraint 'http://schemas.xmlsoap.org/ wsdl/:portType
' validation has failed. Either a key is missing or the existing key
has an empt
y node. Line 375, position 7285.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountServiceSOAP
11Binding' is invalid according to its datatype 'http://www.w3.org/ 2001/XMLSchem
a:NCName' - The '/' character, hexadecimal value 0x2F, cannot be
included in a n
ame. Line 375, position 14719.
- Warning: The 'type' attribute is invalid - The value 'ns0:v3/
AccountService
PortType' is invalid according to its datatype 'http://www.w3.org/2001/ XMLSchema
:QName' - The '/' character, hexadecimal value 0x2F, cannot be
included in a nam
e. Line 375, position 14757.
- Warning: The identity constraint 'http://schemas.xmlsoap.org/ wsdl/:binding'
validation has failed. Either a key is missing or the existing key
has an empty
node. Line 375, position 14706.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountServiceSOAP
12Binding' is invalid according to its datatype 'http://www.w3.org/ 2001/XMLSchem
a:NCName' - The '/' character, hexadecimal value 0x2F, cannot be
included in a n
ame. Line 375, position 22054.
- Warning: The 'type' attribute is invalid - The value 'ns0:v3/
AccountService
PortType' is invalid according to its datatype 'http://www.w3.org/2001/ XMLSchema
:QName' - The '/' character, hexadecimal value 0x2F, cannot be
included in a nam
e. Line 375, position 22092.
- Warning: The identity constraint 'http://schemas.xmlsoap.org/ wsdl/:binding'
validation has failed. Either a key is missing or the existing key
has an empty
node. Line 375, position 22041.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountServiceHttp
Binding' is invalid according to its datatype 'http://www.w3.org/2001/ XMLSchema:
NCName' - The '/' character, hexadecimal value 0x2F, cannot be
included in a nam
e. Line 375, position 29519.
- Warning: The 'type' attribute is invalid - The value 'ns0:v3/
AccountService
PortType' is invalid according to its datatype 'http://www.w3.org/2001/ XMLSchema
:QName' - The '/' character, hexadecimal value 0x2F, cannot be
included in a nam
e. Line 375, position 29555.
- Warning: The identity constraint 'http://schemas.xmlsoap.org/ wsdl/:binding'
validation has failed. Either a key is missing or the existing key
has an empty
node. Line 375, position 29506.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountService' is
invalid according to its datatype 'http://www.w3.org/2001/ XMLSchema:NCName' - T
he '/' character, hexadecimal value 0x2F, cannot be included in a
name. Line 375
, position 34663.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountServiceSOAP
11port_https' is invalid according to its datatype 'http://www.w3.org/ 2001/XMLSc
hema:NCName' - The '/' character, hexadecimal value 0x2F, cannot be
included in
a name. Line 375, position 34699.
- Warning: The 'binding' attribute is invalid - The value 'ns0:v3/
AccountServ
iceSOAP11Binding' is invalid according to its datatype 'http://
www.w3.org/2001/X MLSchema:QName' - The '/' character, hexadecimal value 0x2F, cannot be
included
in a name. Line 375, position 34740.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountServiceSOAP
12port_https' is invalid according to its datatype 'http://www.w3.org/ 2001/XMLSc
hema:NCName' - The '/' character, hexadecimal value 0x2F, cannot be
included in
a name. Line 375, position 34892.
- Warning: The 'binding' attribute is invalid - The value 'ns0:v3/
AccountServ
iceSOAP12Binding' is invalid according to its datatype 'http://
www.w3.org/2001/X MLSchema:QName' - The '/' character, hexadecimal value 0x2F, cannot be
included
in a name. Line 375, position 34933.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountServiceHttp
port' is invalid according to its datatype 'http://www.w3.org/2001/ XMLSchema:NCN
ame' - The '/' character, hexadecimal value 0x2F, cannot be included
in a name.
Line 375, position 35087.
- Warning: The 'binding' attribute is invalid - The value 'ns0:v3/
AccountServ
iceHttpBinding' is invalid according to its datatype 'http://
www.w3.org/2001/XML Schema:QName' - The '/' character, hexadecimal value 0x2F, cannot be
included in
a name. Line 375, position 35120.
- Warning: The identity constraint 'http://schemas.xmlsoap.org/ wsdl/:service'
validation has failed. Either a key is missing or the existing key
has an empty
node. Line 375, position 34650.
Schema validation error: Schema item 'complexType' named
'AdSenseApiException' f
rom namespace 'http://www.google.com/api/adsense/v3' is invalid.
Undefined compl
exType 'http://www.w3.org/2001/XMLSchema:Exception' is used as a base
for comple
x type extension.
Warning: Schema could not be validated. Class generation may fail or
may produce
incorrect results.
Writing file 'C:\Program Files\Microsoft Visual Studio 8\VC
\v3AccountServiceInte
rfaces.cs'.
</pre>
Generating Client Classes:
<pre>
C:\Program Files\Microsoft Visual Studio 8\VC>wsdl https://sandbox.google.com/ap i/adsense/v3/AccountService?wsdl
Microsoft (R) Web Services Description Language Utility
[Microsoft (R) .NET Framework, Version 2.0.50727.42]
Copyright (C) Microsoft Corporation. All rights reserved.
Warning: This web reference does not conform to WS-I Basic Profile
v1.1.
R2028, R2029: A DESCRIPTION using the WSDL namespace and the WSDL SOAP
binding n
amespace MUST be valid according to the XML Schemas found at http://schemas.xmls oap.org/wsdl/2003-02-11.xsd and http://schemas.xmlsoap.org/wsdl/soap/2003-02-11.
xsd.
- Warning: The 'name' attribute is invalid - The value 'v3/
AccountServicePort
Type' is invalid according to its datatype 'http://www.w3.org/2001/ XMLSchema:NCN
ame' - The '/' character, hexadecimal value 0x2F, cannot be included
in a name.
Line 375, position 7299.
- Warning: The element 'operation' in namespace 'http://
schemas.xmlsoap.org/w
sdl/' has invalid child element 'fault' in namespace 'http://
schemas.xmlsoap.org
/wsdl/'. List of possible elements expected: 'output' in namespace
'http://schem as.xmlsoap.org/wsdl/'. Line 375, position 8100.
- Warning: The element 'operation' in namespace 'http://
schemas.xmlsoap.org/w
sdl/' has invalid child element 'fault' in namespace 'http://
schemas.xmlsoap.org
/wsdl/'. List of possible elements expected: 'output' in namespace
'http://schem as.xmlsoap.org/wsdl/'. Line 375, position 11087.
- Warning: The element 'operation' in namespace 'http://
schemas.xmlsoap.org/w
sdl/' has invalid child element 'fault' in namespace 'http://
schemas.xmlsoap.org
/wsdl/'. List of possible elements expected: 'output' in namespace
'http://schem as.xmlsoap.org/wsdl/'. Line 375, position 11394.
- Warning: The element 'operation' in namespace 'http://
schemas.xmlsoap.org/w
sdl/' has invalid child element 'fault' in namespace 'http://
schemas.xmlsoap.org
/wsdl/'. List of possible elements expected: 'output'
...
Unfortunately, Visual Studio has several issues parsing WSDLs
generated by our service. The good news is that I'm working on some
edits that should clear up the vast number of these. I'll definitely
make a posting to the group when they're done.
Cheers,
Wes
On Oct 6, 2:11 am, mr_road <james.ather...@gmail.com> wrote:
> I have just been trying to generate a service and clients in VS2005
> for the AccountService. The wsdl.exe tool successfully generated a
> Service Interface and Client classes, but in the process threw a large
> number of errors. Please see below. I was wondering what had caused
> this and if there were any plans to fix these errors. I have not
> written any code using these classes yet, I will post again when I do.
> Generating serverInterface Class:
> <pre>
> Setting environment for using Microsoft Visual Studio 2005 x86 tools.
> C:\Program Files\Microsoft Visual Studio 8\VC>wsdl /language:CS /
> serverInterface
> https://sandbox.google.com/api/adsense/v3/AccountService?wsdl > Microsoft (R) Web Services Description Language Utility
> [Microsoft (R) .NET Framework, Version 2.0.50727.42]
> Copyright (C) Microsoft Corporation. All rights reserved.
> Warning: This web reference does not conform to WS-I Basic Profile
> v1.1.
> R2028, R2029: A DESCRIPTION using the WSDL namespace and the WSDL SOAP
> binding n
> amespace MUST be valid according to the XML Schemas found athttp://schemas.xmls > oap.org/wsdl/2003-02-11.xsd andhttp://schemas.xmlsoap.org/wsdl/soap/2003-02-11.
> xsd.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountServicePort
> Type' is invalid according to its datatype 'http://www.w3.org/2001/ > XMLSchema:NCN
> ame' - The '/' character, hexadecimal value 0x2F, cannot be included
> in a name.
> Line 375, position 7299.
> - Warning: The element 'operation' in namespace 'http://
> schemas.xmlsoap.org/w
> sdl/' has invalid child element 'fault' in namespace 'http://
> schemas.xmlsoap.org
> /wsdl/'. List of possible elements expected: 'output' in namespace
> 'http://schem > as.xmlsoap.org/wsdl/'. Line 375, position 8100.
> - Warning: The element 'operation' in namespace 'http://
> schemas.xmlsoap.org/w
> sdl/' has invalid child element 'fault' in namespace 'http://
> schemas.xmlsoap.org
> /wsdl/'. List of possible elements expected: 'output' in namespace
> 'http://schem > as.xmlsoap.org/wsdl/'. Line 375, position 11087.
> - Warning: The element 'operation' in namespace 'http://
> schemas.xmlsoap.org/w
> sdl/' has invalid child element 'fault' in namespace 'http://
> schemas.xmlsoap.org
> /wsdl/'. List of possible elements expected: 'output' in namespace
> 'http://schem > as.xmlsoap.org/wsdl/'. Line 375, position 11394.
> - Warning: The element 'operation' in namespace 'http://
> schemas.xmlsoap.org/w
> sdl/' has invalid child element 'fault' in namespace 'http://
> schemas.xmlsoap.org
> /wsdl/'. List of possible elements expected: 'output' in namespace
> 'http://schem > as.xmlsoap.org/wsdl/'. Line 375, position 12970.
> - Warning: The identity constraint 'http://schemas.xmlsoap.org/ > wsdl/:portType
> ' validation has failed. Either a key is missing or the existing key
> has an empt
> y node. Line 375, position 7285.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountServiceSOAP
> 11Binding' is invalid according to its datatype 'http://www.w3.org/ > 2001/XMLSchem
> a:NCName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in a n
> ame. Line 375, position 14719.
> - Warning: The 'type' attribute is invalid - The value 'ns0:v3/
> AccountService
> PortType' is invalid according to its datatype 'http://www.w3.org/2001/ > XMLSchema
> :QName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in a nam
> e. Line 375, position 14757.
> - Warning: The identity constraint 'http://schemas.xmlsoap.org/ > wsdl/:binding'
> validation has failed. Either a key is missing or the existing key
> has an empty
> node. Line 375, position 14706.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountServiceSOAP
> 12Binding' is invalid according to its datatype 'http://www.w3.org/ > 2001/XMLSchem
> a:NCName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in a n
> ame. Line 375, position 22054.
> - Warning: The 'type' attribute is invalid - The value 'ns0:v3/
> AccountService
> PortType' is invalid according to its datatype 'http://www.w3.org/2001/ > XMLSchema
> :QName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in a nam
> e. Line 375, position 22092.
> - Warning: The identity constraint 'http://schemas.xmlsoap.org/ > wsdl/:binding'
> validation has failed. Either a key is missing or the existing key
> has an empty
> node. Line 375, position 22041.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountServiceHttp
> Binding' is invalid according to its datatype 'http://www.w3.org/2001/ > XMLSchema:
> NCName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in a nam
> e. Line 375, position 29519.
> - Warning: The 'type' attribute is invalid - The value 'ns0:v3/
> AccountService
> PortType' is invalid according to its datatype 'http://www.w3.org/2001/ > XMLSchema
> :QName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in a nam
> e. Line 375, position 29555.
> - Warning: The identity constraint 'http://schemas.xmlsoap.org/ > wsdl/:binding'
> validation has failed. Either a key is missing or the existing key
> has an empty
> node. Line 375, position 29506.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountService' is
> invalid according to its datatype 'http://www.w3.org/2001/ > XMLSchema:NCName' - T
> he '/' character, hexadecimal value 0x2F, cannot be included in a
> name. Line 375
> , position 34663.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountServiceSOAP
> 11port_https' is invalid according to its datatype 'http://www.w3.org/ > 2001/XMLSc
> hema:NCName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in
> a name. Line 375, position 34699.
> - Warning: The 'binding' attribute is invalid - The value 'ns0:v3/
> AccountServ
> iceSOAP11Binding' is invalid according to its datatype 'http://www.w3.org/2001/X > MLSchema:QName' - The '/' character, hexadecimal value 0x2F, cannot be
> included
> in a name. Line 375, position 34740.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountServiceSOAP
> 12port_https' is invalid according to its datatype 'http://www.w3.org/ > 2001/XMLSc
> hema:NCName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in
> a name. Line 375, position 34892.
> - Warning: The 'binding' attribute is invalid - The value 'ns0:v3/
> AccountServ
> iceSOAP12Binding' is invalid according to its datatype 'http://www.w3.org/2001/X > MLSchema:QName' - The '/' character, hexadecimal value 0x2F, cannot be
> included
> in a name. Line 375, position 34933.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountServiceHttp
> port' is invalid according to its datatype 'http://www.w3.org/2001/ > XMLSchema:NCN
> ame' - The '/' character, hexadecimal value 0x2F, cannot be included
> in a name.
> Line 375, position 35087.
> - Warning: The 'binding' attribute is invalid - The value 'ns0:v3/
> AccountServ
> iceHttpBinding' is invalid according to its datatype 'http://www.w3.org/2001/XML > Schema:QName' - The '/' character, hexadecimal value 0x2F, cannot be
> included in
> a name. Line 375, position 35120.
> - Warning: The identity constraint 'http://schemas.xmlsoap.org/ > wsdl/:service'
> validation has failed. Either a key is missing or the existing key
> has an empty
> node. Line 375, position 34650.
> Schema validation error: Schema item 'complexType' named
> 'AdSenseApiException' f
> rom namespace 'http://www.google.com/api/adsense/v3'is invalid.
> Undefined compl
> exType 'http://www.w3.org/2001/XMLSchema:Exception'is used as a base
> for comple
> x type extension.
> Warning: Schema could not be validated. Class generation may fail or
> may produce
> incorrect results.
> Writing file 'C:\Program Files\Microsoft Visual Studio 8\VC
> \v3AccountServiceInte
> rfaces.cs'.
> </pre>
> Generating Client Classes:
> <pre>
> C:\Program Files\Microsoft Visual Studio 8\VC>wsdlhttps://sandbox.google.com/ap > i/adsense/v3/AccountService?wsdl
> Microsoft (R) Web Services Description Language Utility
> [Microsoft (R) .NET Framework, Version 2.0.50727.42]
> Copyright (C) Microsoft Corporation. All rights reserved.
> Warning: This web reference does not conform to WS-I Basic Profile
> v1.1.
> R2028, R2029: A DESCRIPTION using the WSDL namespace and the WSDL SOAP
> binding n
> amespace MUST be valid according to the XML Schemas found athttp://schemas.xmls > oap.org/wsdl/2003-02-11.xsd andhttp://schemas.xmlsoap.org/wsdl/soap/2003-02-11.
> xsd.
> - Warning: The 'name' attribute is invalid - The value 'v3/
> AccountServicePort
> Type' is invalid according to its datatype 'http://www.w3.org/2001/ > XMLSchema:NCN
> ame' - The '/' character, hexadecimal value 0x2F, cannot be included
> in a name.
> Line 375, position 7299.
> - Warning: The element 'operation' in namespace 'http://
> schemas.xmlsoap.org/w
> sdl/' has invalid child element 'fault' in namespace 'http://
> schemas.xmlsoap.org
> /wsdl/'. List of possible elements expected: 'output' in namespace
> 'http://schem > as.xmlsoap.org/wsdl/'. Line 375, position 8100.
> -