VMware Cloud Community
CloudAutoCraft
Enthusiast
Enthusiast

Get VC:VirtualMachine from vCAC:VirtualMachine or vCAC:Entity

I'm having a heckuva time finding a way to retrieve the corresponding VC:VirtualMachine after I've already got both the vCAC:VirtualMachine and vCAC:Entity objects for the virtual machine.  Can anyone please offer pointers? 

It would be nice if I could just utilize my vCAC objects, but I'm wiring in some workflows from a 3rd-party package that heavily use the VC:virtualmachine object type, so I need to do this translation. 

Preference:

I would prefer to match on whatever VC property matches the VCAC property VirtualMachine.Admin.UUID rather than on Name, to avoid possible confusion (since it's possible to have multiple virtual machines with the same name in the same vCenter). 

Any help / pointers would be very much appreciated.  Thanks in advance!

0 Kudos
2 Replies
iiliev
VMware Employee
VMware Employee

0 Kudos
CloudAutoCraft
Enthusiast
Enthusiast

Thank you!  I searched 14 different ways looking for a thread that had already answered this and couldn't find it.  Thanks for the link, iiliev‌!

0 Kudos