6.0
Table Of Contents
- vSphere Web Services SDK Developer’s Setup Guide
- Contents
- About the vSphere Web Services SDK
- Knowledge Required for Using the vSphere Web Services SDK
- Programming Languages Supported by the vSphere Web Services SDK
- Types of Applications That You Can Build Using This SDK
- Downloading the vSphere Web Services SDK
- vSphere Web Services SDK Package Contents
- SDK Versions and VMware vSphere Product Compatibility
- Setting Up for Java Development
- Setting Up for Microsoft C# Development
- vSphere Server Certificates
- Scripting the C# DLL Build
- Index
vSphere Web Services SDK Developer’s Setup Guide
24 VMware, Inc.
Example 3-1. Sample Output of a Successful Run of SimpleClient
Object Type : Datacenter
Reference Value : ha-datacenter
Property Name : name
Property Value : ha-datacenter
Object Type : Folder
Reference Value : ha-folder-root
Property Name : name
Property Value : ha-folder-root
Troubleshooting the Setup
If you cannot successfully run the SimpleClient, first check your environment settings and all other setup
tasks.
Proxy Server Connection Problem
You might have a proxy connection problem.
Problem
The sample application reports that it is unable to connect to the remote server. For example:
SimpleClient.exe https://<management-server>/sdk <user> <pass>
Caught Exception : Name : WebException Message : Unable to connect to the remote server
Trace : at System.Net.HttpWebRequest.GetRequestStream() at
System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[]
parameters) at VimApi.VimService.RetrieveServiceContent(ManagedObjectReference _this) ...
Exception disconnecting.
Caught Exception : Name : NullReferenceException Message : Object reference not set to an instance
of an object.
Trace: ...
Cause
Cannot connect to the Web service from Microsoft .NET client sample through the proxy server.
Solution
Try a different server on the same subnet as the client.
sgen Configuration Issues
The sgen tool used to generate XML serializer assemblies might be configured incorrectly.
Problem
The sgen tool gives unexpected results.
Cause
The behavior of the sgen tool varies depending on what you have in your Machine.config file. For example,
by default sgen is supposed to output optimized non-debug code, but that is not always the case.
Solution
Adjust your sgen configuration. To get more debugging information, use the /k flag, which causes sgen to
keep all its temporary generated files, including the source files and command-line option files