Bug 1353175 - Remove old API of template disks and replace it with the new diskattachments API
Summary: Remove old API of template disks and replace it with the new diskattachments API
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: RestAPI
Version: 4.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ovirt-4.0.1
: 4.0.1.1
Assignee: Tal Nisan
QA Contact: Carlos Mestre González
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-07-06 11:34 UTC by Tal Nisan
Modified: 2017-11-19 10:32 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-07-19 06:26:28 UTC
oVirt Team: Storage
Embargoed:
rule-engine: ovirt-4.0.z+
rule-engine: blocker+
rule-engine: planning_ack+
tnisan: devel_ack+
rule-engine: testing_ack+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1346918 0 unspecified CLOSED Remove old API of VM disks 2021-02-22 00:41:40 UTC
oVirt gerrit 60259 0 master MERGED Introduce template diskattachments resources and remove old API 2016-07-07 14:50:47 UTC
oVirt gerrit 60260 0 master MERGED restapi: Remove old template disks API and introduce template attachments 2016-07-11 11:37:11 UTC
oVirt gerrit 60349 0 model_4.0 MERGED Introduce template diskattachments resources and remove old API 2016-07-07 14:55:41 UTC
oVirt gerrit 60453 0 ovirt-engine-4.0 MERGED restapi: Remove old template disks API and introduce template attachments 2016-07-11 13:44:53 UTC
oVirt gerrit 60509 0 ovirt-engine-4.0.1 MERGED restapi: Remove old template disks API and introduce template attachments 2016-07-11 14:11:01 UTC

Internal Links: 1346918

Description Tal Nisan 2016-07-06 11:34:14 UTC
Description of problem:

Currently V4 API still supports V3 lists and actions on template disks in:

api/templates/{template_id}/disks
api/templates/{template_id}/disks/{disk_id}

Those should be removed and the functionality and the new functionality should be added in:

api/templates/{template_id}/diskattachments
api/templates/{template_id}/diskattachments/{disk_attachment_id}

The functionality in V4 resources used by delegation from V3 should be moved to V3 classes

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Allon Mureinik 2016-07-14 15:37:24 UTC
Tal - not sure if this is just documented in the REST documentation already or requires a specific treatment, but flagging as requires-doctext? just to be on the safe side. If it's redundant, feel free to set - instead.

Comment 2 Carlos Mestre González 2016-07-18 12:07:27 UTC
/disks/ returns 404, diskattachments works for single/multiple disks. I tested also different values creating multiple templates and vms fro m those templates.


Regarding methods:

/templates/{template:id}/diskattachments/ allows HEAD, DELETE, GET, OPTIONS
/templates/{template:id}/diskattachments/{disk_attachment:id} allows HEAD, GET, OPTIONS

DELETE works as expected when the disk is copied to multiple storage domains (and is documented on the api)

version: 4.0.1.1-0.1.el7ev

Comment 3 Sandro Bonazzola 2016-07-19 06:26:28 UTC
Since the problem described in this bug report should be
resolved in oVirt 4.0.1 released on July 19th 2016, it has been closed with a
resolution of CURRENT RELEASE.

For information on the release, and how to update to this release, follow the link below.

If the solution does not work for you, open a new bug report.

http://www.ovirt.org/release/4.0.1/


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