Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1096497 - [restapi] Display image size and type for glance images missing in RESTAPI
[restapi] Display image size and type for glance images missing in RESTAPI
Status: CLOSED CURRENTRELEASE
Product: ovirt-engine
Classification: oVirt
Component: RestAPI (Show other bugs)
3.4.0
Unspecified Unspecified
high Severity medium (vote)
: ovirt-4.2.0
: 4.2.0
Assigned To: shani
Raz Tamir
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2014-05-11 04:48 EDT by Gadi Ickowicz
Modified: 2017-12-24 04:17 EST (History)
12 users (show)

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Glance images returned by the REST API now list their size and type (iso/disk).
Story Points: ---
Clone Of:
Environment:
Last Closed: 2017-12-20 05:51:28 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: Storage
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
rule-engine: ovirt‑4.2+


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
oVirt gerrit 80627 master POST restapi: Display image size and type for glance images 2017-08-28 07:23 EDT
oVirt gerrit 80628 master POST Add size and type properties to Image 2017-08-15 09:14 EDT
oVirt gerrit 80663 master MERGED Add size and type properties to Image 2017-08-28 03:56 EDT
oVirt gerrit 80691 master MERGED The Image.size needs to be long 2017-08-20 05:07 EDT
oVirt gerrit 81134 master MERGED restapi: Update to model 4.2.16 and metamodel 1.2.10 2017-08-29 05:22 EDT

  None (edit)
Description Gadi Ickowicz 2014-05-11 04:48:39 EDT
Description of problem:
Currently Glance images returned by RESTAPI do not list their size or type (iso/disk), however the webadmin does list this information.

Currently the only following information is returned:

<image href="/api/images/25c5e604-c517-457b-9142-2a6cdfdfefe0" id="25c5e604-c517-457b-9142-2a6cdfdfefe0">
 <actions>
  <link href="/api/images/25c5e604-c517-457b-9142-2a6cdfdfefe0/import" rel="import"/>
 </actions>
 <name>RHEL-ACTIVE</name>
</image>
Comment 3 Yaniv Lavi 2016-12-05 06:08:31 EST
I consider gaps in REST API bugs, not feature. We should try to tackle this.
Comment 4 shani 2017-08-10 10:36:22 EDT
Bug is still valid.

Steps to Reproduce:
Using the REST API, run the following:

Method:
-------
GET

URL:
----
http://xxxxx:8080/ovirt-engine/api/storagedomains/<ovirt-image-repository-id>/images/<glance-image-id>

Response:
Response Body (Raw):
--------------------
<image href="/ovirt-engine/api/storagedomains/072fbaa1-08f3-4a40-9f34-a5ca22dd1d74/images/b393fde0-5a67-4323-a1ab-9031dd2f9b97" id="b393fde0-5a67-4323-a1ab-9031dd2f9b97">
    <actions>
        <link href="/ovirt-engine/api/storagedomains/072fbaa1-08f3-4a40-9f34-a5ca22dd1d74/images/b393fde0-5a67-4323-a1ab-9031dd2f9b97/import" rel="import"/>
    </actions>
    <name>CentOS 6 Generic Cloud Image v1604 for x86_64</name>
    <storage_domain href="/ovirt-engine/api/storagedomains/072fbaa1-08f3-4a40-9f34-a5ca22dd1d74" id="072fbaa1-08f3-4a40-9f34-a5ca22dd1d74"/>
</image>
Comment 5 Allon Mureinik 2017-09-03 05:01:19 EDT
All the patches seem to be merged, moving to MODIFIED.
Shani, if something is missing here, please advise and return the BZ to POST.
Comment 6 Raz Tamir 2017-09-04 11:15:01 EDT
Verified on ovirt-engine-4.2.0-0.0.master.20170903205106.gitb17261a.el7.centos


<size>3623878656</size>
<type>disk</type>

Are now part of image object in api/storagedomains/{sd_id}/images/{img_id}
Comment 7 Sandro Bonazzola 2017-12-20 05:51:28 EST
This bugzilla is included in oVirt 4.2.0 release, published on Dec 20th 2017.

Since the problem described in this bug report should be
resolved in oVirt 4.2.0 release, published on Dec 20th 2017, it has been closed with a resolution of CURRENT RELEASE.

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

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