Bug 2013697 - [REST API] Incorrect disk_snapshot parent href in api/disks/xxx/disksnapshots
Summary: [REST API] Incorrect disk_snapshot parent href in api/disks/xxx/disksnapshots
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: RestAPI
Version: 4.4.9.1
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: ovirt-4.5.3
: ---
Assignee: Artiom Divak
QA Contact: Ilia Markelov
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-10-13 14:50 UTC by Mark Kemel
Modified: 2022-09-19 14:30 UTC (History)
4 users (show)

Fixed In Version: ovirt-engine-4.5.3
Clone Of:
Environment:
Last Closed: 2022-09-19 14:30:59 UTC
oVirt Team: Storage
Embargoed:
sbonazzo: ovirt-4.5-


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github oVirt ovirt-engine pull 283 0 None open restapi: fix hrefs in single GET disksnapshot request 2022-04-24 19:26:35 UTC
Github oVirt ovirt-engine pull 549 0 None open restapi: incorrect href for parent href 2022-08-04 08:38:31 UTC
Red Hat Issue Tracker RHV-43803 0 None None None 2021-10-13 14:53:15 UTC

Description Mark Kemel 2021-10-13 14:50:54 UTC
Description of problem:
When requesting disk snapshots of a disk (ovirt-engine/api/disks/{diskid}/disksnapshots or ovirt-engine/api/disks/{diskid}/disksnapshots/{snapshotid}), the 'parent' element holds incorrect href - disk href instead of the disksnapshot href.

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


How reproducible:
100%

Steps to Reproduce:
1. Create at least one disk snapshot
2. Issue REST API request ovirt-engine/api/disks/{diskid}/disksnapshots?include_active&include_template or ovirt-engine/api/disks/{diskid}/disksnapshots/{snapshotid}

Actual results:
On disk snapshots that have the <parent> element, the href attribute will be like this:
<parent href="/ovirt-engine/api/disks/71b3d7c7-19ee-4b14-adb5-17422e1e7407" id="af16f154-f973-46ee-9683-5c456e3cb51e"/>

Expected results:
<parent href="/ovirt-engine/api/disks/71b3d7c7-19ee-4b14-adb5-17422e1e7407/disksnapshots/af16f154-f973-46ee-9683-5c456e3cb51e" id="af16f154-f973-46ee-9683-5c456e3cb51e"/>

Additional info:
Note that when 'include_template' flag is requested, and one of the disk_snapshots have a template disk as a parent (as described here https://bugzilla.redhat.com/1900597) - this template disk snapshot belongs to another disk, thus the href should be built accordingly.

Comment 3 Michal Skrivanek 2022-04-11 08:50:07 UTC
No update for a while, didn't make it in time for 4.5, closing

Comment 4 Ilia Markelov 2022-06-15 12:09:08 UTC
Failed verification.

Still getting the wrong result for ovirt-engine/api/disks/{diskid}/disksnapshots request on engine-4.5.1.1-0.14.el8ev

Comment 5 Casper (RHV QE bot) 2022-09-19 14:30:59 UTC
This bug has low overall severity and passed an automated regression suite, and is not going to be further verified by QE. If you believe special care is required, feel free to re-open to ON_QA status.


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