Bug 1333045 - original template field is not exposed to REST API
Summary: original template field is not exposed to REST API
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: RestAPI
Version: 3.6.5
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ovirt-4.1.0-alpha
: 4.1.0.2
Assignee: Marek Libra
QA Contact: sefi litmanovich
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-05-04 14:49 UTC by enax
Modified: 2017-02-07 04:03 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
A new 'original_template' property has been introduced for the 'vm' REST API resource. This enables the user to get information about the template the virtual machine was based on before cloning.
Clone Of:
Environment:
Last Closed: 2017-02-01 14:35:22 UTC
oVirt Team: Virt
Embargoed:
rule-engine: ovirt-4.1+
rule-engine: planning_ack+
tjelinek: devel_ack+
mavital: testing_ack+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 60407 0 master MERGED Add Original Template Link to the VM 2016-07-12 07:54:31 UTC
oVirt gerrit 60457 0 master MERGED restapi: Add Original Template link to Vm 2016-08-22 11:37:38 UTC

Description enax 2016-05-04 14:49:59 UTC
Description of problem:

Down there is the last email from Tomas Jelinek, the full thread can be found here: http://lists.ovirt.org/pipermail/users/2016-May/039622.html

the thing is that:
- if you create a VM from a template using the "clone" provisioning the VM is detached from the VM and is considered to be based on Blank
- this is why the VM dialog shows blank and the REST returns blank
- there has been a feature implemented (in 3.5 IIRC) which introduced the concept of "original template" - so we remember also what template it was cloned from (both name and ID)
- it seems this particular field is not exposed to REST API, only to UI

Comment 1 Sandro Bonazzola 2016-12-12 13:54:56 UTC
The fix for this issue should be included in oVirt 4.1.0 beta 1 released on December 1st. If not included please move back to modified.

Comment 2 sefi litmanovich 2016-12-19 08:38:13 UTC
Verified with ovirt-engine-4.1.0-0.2.master.20161218144454.gitbaa2853.el7.centos.noarch.

original_template attribute in vm API links to the original template where the original vm was created from.
In a vm created from template the link is the same as template attribute.
In cloned vms (tried clone from vm/template/snapshot) template attribute links to Blank template and original_template to the template of the source.


Note You need to log in before you can comment on or make changes to this bug.