Bug 1458668 - VM pool auto_storage_select flag doesn't return Validation error
Summary: VM pool auto_storage_select flag doesn't return Validation error
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: RestAPI
Version: 4.1.7.6
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ovirt-4.2.0
: ---
Assignee: Tomas Jelinek
QA Contact: Radim Hrazdil
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-06-05 07:32 UTC by Vladimir
Modified: 2017-12-20 10:49 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-12-20 10:49:56 UTC
oVirt Team: Virt
Embargoed:
rule-engine: ovirt-4.2+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 79433 0 master MERGED core: dont allow to change auto storage select 2017-07-17 15:27:00 UTC

Description Vladimir 2017-06-05 07:32:05 UTC
Description of problem:
Rest API doesn't return error in case of auto_storage_select is set to False for existing VM pool

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


How reproducible:


Steps to Reproduce:
1. Create VM pool with auto_storage_select: True
2. Try to disable auto_storage_select via REST API
3.

Actual results:
auto_storage_select is enabled, but no error returned

Expected results:
auto_storage_select flag is enabled, API returns Validation Error with message like : You cannot disable auto_storage_select for existing VM pool

Additional info:

Comment 1 Tomas Jelinek 2017-06-06 14:10:20 UTC
it actually does change the value of it, but it should not. So there indeed is a missing validation.

Comment 2 Vladimir 2017-09-29 13:22:59 UTC
Is it correct behaviour to change it's value? We have and testcase in the polarion that says it can't be update after pool creation

https://polarion.engineering.redhat.com/polarion/#/project/RHEVM3/workitem?id=RHEVM-17366&revision=1574780

Comment 3 Vladimir 2017-09-29 13:23:35 UTC
Since now it can be disabled via REST API but not via UI

Comment 4 Tomas Jelinek 2017-09-29 13:59:02 UTC
It is not a correct behavior to change that value. It has to return a validation error.

Comment 5 Tomas Jelinek 2017-11-24 10:14:21 UTC
Can you give a bit more details on why is it failed qe?
I have just tried to use the API to change the auto_storage_select from true to false and have received this msg:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<fault>
    <detail>[Cannot change VM-Pool automatic selection of target storage domains during disks allocation.]</detail>
    <reason>Operation Failed</reason>
</fault>

Is it not what happens to you? Can you please provide what the API returns on GET of that pool, what you send it to update the pool and what it answers?

Comment 6 Vladimir 2017-11-27 08:30:12 UTC
Indeed this is true for 4.2.0
But on 4.1.8-0.1.el7 it returns you 200 response code, and says that auto_storage_select parameter was updated

Comment 7 Michal Skrivanek 2017-11-27 11:32:35 UTC
and 4.2 is a release where the bug was fixed

Comment 8 Vladimir 2017-11-27 14:29:21 UTC
Verified on 4.2.0-0.0.master.20171112130303.git8bc889c.el7.centos

Comment 9 Sandro Bonazzola 2017-12-20 10:49:56 UTC
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.