VMware

This Question is Possibly Answered

1 "correct" answer available (10 pts) 2 "helpful" answers available (6 pts)
13 Replies Last post: Nov 11, 2009 4:22 PM by janetdoyle  

Can we use vim2.5 to connect to ESX3.0 and ESX 3.5? posted: Sep 14, 2009 8:15 AM

Click to view haroon09's profile Novice 26 posts since
Jul 10, 2006
Can we use vim2.5 to connect to ESX3.0 and ESX 3.5? I found from the samples that we have to connec to vim2.0 and then if ESX supports vim2.5 we can convert the ManagedObject to vim2.5 type and can access new vim2.5 methods. It is hassel to include two vims in the project.
Click to view storm27's profile Enthusiast 41 posts since
May 4, 2009

Hi,

vim25 namespace contains the new data objects, managed objects and APIs which have been released with ESX 3.5 onwards. It is also backward compatible with vim2, so you can very well connect to ESX 3.0.x using either of the two (vim2 or vim25) i.e with both of these still availiable, code that is written for ESX 3.0.x and VC 2.0 is still usable with newer ESX 3.5 and VC 2.5 ( and onwards) releases.But, with 3.0 you won't be able to leverage the new APIs that have been introduced after 3.5.

You can refer to below link for furtther clarification,if needed.

Hope this helps!

  • Angela
Click to view storm27's profile Enthusiast 41 posts since
May 4, 2009

Hi,

vim25 defines the namespace which contains the stub bindings,for the management APIs, for the ESX versions 2.5 and above.It contains the support for the new objects and the APIs that were added after 2.0. vim25 is also backward compatible with vim2 i.e it provides supports for the old objects and APIs and new ones as well.

In an effort to maintain backward compatibilty, the VI SDK 2.5 (and onwards) includes both vim25 and vim2 namespaces. With both of these still available, the code that is written for ESX 3.0.x or VC 2.0 is still usable with the newer releases ( ESX 3.5 onwards and VC 2.5 onwards).

Hope this helps!

-Angela

Click to view storm27's profile Enthusiast 41 posts since
May 4, 2009

You need to include vim2 namesoave in order to connect to ESX 3.0.x

Thanks.

Click to view janetdoyle's profile Novice 9 posts since
Sep 15, 2009
This is a pretty good question. And I'm surprised this hasn't been answered yet. I'm coding for environment that has VC2 to VC4. I've found that using VIM4.wsdl does not work with VC2 it won't even connect. I can use VIM2.wsdl with VC4 but then I can't get the features that VC2.5+ provide (sensors, etc). Coding in C++ so the ugly java implementation of coding two classes one for each version will not work and is not very OO.

Has anyone tried merging VIM/VIM4.wsdls? The namespace idea above sounds interesting can anyone elaborate?

Thanks,
Jan

Click to view AngelaS's profile Enthusiast 44 posts since
Sep 28, 2009
vim.wsdl : This wsdl is to be used in conjunction with ESX 3.0.x and VirtualCenter 2.0.x

vim25.wsdl : This wsdl is to be used in conjunction with ESX 3.5, ESXi 3.5, VirtualCenter 2.5, ESX 4.0, ESXi 4.0 and vCenter Server 4.0

In case your client application requires to support mixed server environments (for example, ESX 3.x and ESX 4.x), then you need to retrieve the API version that is supported on the server and then accordingly design the client-side logic. Section "Supporting Multiple API Versions" of Chapter 6, Client Application Pattern, of vSphere Web Services SDK Programming Guide, provides further details on how this can be achieved.

http://www.vmware.com/support/developer/vc-sdk/visdk400pubs/sdk40programmingguide.pdf

Also, you might would like to refer to the forum thread http://communities.vmware.com/message/1290928#1290928 for using vim service for different ESX versions.

Hope the above information is helpful.


Click to view janetdoyle's profile Novice 9 posts since
Sep 15, 2009

Angela,

Thanks for the links. So I still need to use two WSDLs. I can default to VIM2.0 but if I want to use new features against VC 2.5+ I have to use VIM 2.5. So couple of questions:

1. How do I use the two WSDLs in C++? Won't there be a conflict in names since some of the function/class names are reused between the wsdls? I use gSoap toolkit to convert my wsdls to C files

2. The link at the end about setting API version in the soap header. Can you explain that?

3. Just to make sure, there's no way to use solely WSDL 2.5 (I can't fudge the namespace and trick VC2 to accept the newer WSDL)?

Are there C++ examples? Java is a bit different since I can just include jar files for VIM2 and VIM2.5.

Thanks,

Jan

Click to view janetdoyle's profile Novice 9 posts since
Sep 15, 2009

Haroon,

Thanks for that tip. I was able to successfully build both wsdls in my project. I used two namespaces for both. I'm defaulting to VIM2 and I plan to switch over to VIM2.5 when I need to use a feature that's not part of VIM2. I should be able to create a new binding (VIM2.5) using the cookie from the connection original connection (VIM2) and then pass that service content along. Correct?

Do you have any examples?

Thanks,

Jan

Click to view janetdoyle's profile Novice 9 posts since
Sep 15, 2009

You've all been very helpful. The size of the binary increased by a lot, though!


Developer Social Media

Communities