Bug 1401873 - Incorrect links in REST API for /imagetransfers
Summary: Incorrect links in REST API for /imagetransfers
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: RestAPI
Version: 4.0.2
Hardware: Unspecified
OS: Unspecified
medium
unspecified
Target Milestone: ovirt-4.0.7
: ---
Assignee: Liron Aravot
QA Contact: Gonza
URL:
Whiteboard:
Depends On:
Blocks: 1422888
TreeView+ depends on / blocked
 
Reported: 2016-12-06 10:24 UTC by Ondra Machacek
Modified: 2017-02-16 13:18 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
: 1422888 (view as bug list)
Environment:
Last Closed: 2017-02-16 13:18:53 UTC
oVirt Team: Storage
Embargoed:
rule-engine: ovirt-4.0.z+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 69723 0 master ABANDONED ImageTransfer - removing image link 2017-01-16 11:31:14 UTC
oVirt gerrit 69797 0 master MERGED ImageTransfer - removing image link 2017-01-16 09:51:17 UTC
oVirt gerrit 70539 0 ovirt-engine-4.1 MERGED ImageTransfer - removing image link 2017-02-08 15:10:43 UTC
oVirt gerrit 71901 0 ovirt-engine-4.0 MERGED ImageTransfer - removing image link 2017-02-08 16:39:43 UTC

Description Ondra Machacek 2016-12-06 10:24:28 UTC
curl https://engine/ovirt-engine/api/imagetransfers/

<image_transfers>
  <image_transfer href="/ovirt-engine/api/imagetransfers/71dff49f-f743-4395-927d-0ee7cf243a66" id="71dff49f-f743-4395-927d-0ee7cf243a66">
    ...
    <image href="/ovirt-engine/api/null/8603e3ed-6d90-4a36-93fa-8bfacef22fea" id="8603e3ed-6d90-4a36-93fa-8bfacef22fea"/>
    ...
  </image_transfer>
</image_transfers>

There is "null" in Image link:

  <image href="/ovirt-engine/api/null/8603e3ed-6d90-4a36-93fa-8bfacef22fea" id="8603e3ed-6d90-4a36-93fa-8bfacef22fea"/>

Also, shouldn't this be disk, instead of image??

Comment 1 Liron Aravot 2017-01-05 15:03:26 UTC
Thanks Ondra,
The cause for the bug here is that we use "image" instead of "disk" in the api- currently when uploading we pass the disk id but as an image which is confusing.

For 4.0 I'm going to remove the link to the image which, on 4.1/4.2 we'll change the api (with backward compatibility) to accept a disk element and we'll have proper link.
Looking forward, when we'll add support to upload to a specific disk snapshot (=image) we'll let the user specify a destination snapshot id within the disk as well (if not specified the 'active' snapshot will be used).

Thanks,
Liron

Comment 2 Liron Aravot 2017-01-05 15:25:10 UTC
Adding, the term "Image" is currently used in our api for glance images import (contains the details of the glance image) aside from the image transfer usage.

Comment 3 Sandro Bonazzola 2017-01-25 07:57:16 UTC
4.0.6 has been the last oVirt 4.0 release, please re-target this bug.


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