-
Notifications
You must be signed in to change notification settings - Fork 455
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
r/virtual_machine: Fix template UUID lookup for older vSphere versions
Historically, the FindByUuid method under SearchIndex did not support looking up VMs marked as template. However, at some point in time, this was changed (possibly vSphere 6.5, based on bug reports), and any mention of the UUID search not supporting templates was removed from the API documentation, without a mention of when support for templates was introduced. Since this is the method that we use to look up both VMs and templates, this means that templates have not been functional for vSphere <= 6.0 users since the resource was re-written in 1.0. There has been a workaround in that the source template is just converted back to virtual machine, but this update fixes it so that on versions of vSphere older than 6.5, we fall back to using ContainerView with a filter on the UUID. This works for all versions of vSphere. We keep FindByUuid for 6.5 as it may possibly be more direct path.
- Loading branch information
1 parent
a4bccbf
commit 18c73ab
Showing
1 changed file
with
79 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters