Bug 1342054

Summary: REST-API (V3) | Change vNIC interface type reset vNIC network to ovirtmgmt
Product: [oVirt] ovirt-engine Reporter: Alona Kaplan <alkaplan>
Component: RestAPIAssignee: Juan Hernández <juan.hernandez>
Status: CLOSED CURRENTRELEASE QA Contact: Michael Burman <mburman>
Severity: high Docs Contact:
Priority: high    
Version: 4.0.0CC: acanan, bugs, mperina, myakove, oourfali, stirabos, tnisan
Target Milestone: ovirt-4.0.0-rcKeywords: Automation, Regression
Target Release: 4.0.0Flags: rule-engine: ovirt-4.0.0+
rule-engine: blocker+
rule-engine: planning_ack+
juan.hernandez: devel_ack+
rule-engine: testing_ack+
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1340607 Environment:
Last Closed: 2016-07-05 07:39:23 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Infra RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1340607    
Bug Blocks:    

Description Alona Kaplan 2016-06-02 10:51:39 UTC
+++ This bug was initially created as a clone of Bug #1340607 +++

Description of problem:
Via REST V3 when changing vNIC interface type the vNIC network is changed to ovirtmgmt.
When doing the same in REST V4 the network doesn't changed to ovirtmgmt.


Version-Release number of selected component (if applicable):
ovirt-engine-4.1.0-0.0.master.20160526111325.git538ad4f.el7.centos.noarch


Steps to Reproduce:
1. Attach vNIC to VM with network 'net-1' and type virtio
2. Unplug the network
3. Via REST (V3) send:
PUT to /ovirt-engine/api/vms/<vm_id>/nics/vnic_id
<nic>
    <interface>e1000</interface>
</nic>

Actual results:

--- Additional comment from Meni Yakove on 2016-05-28 13:16 EDT ---



In the latest nightly the GetVmOvfByVmIdQuery NPE is gone.
Now the issue is when calling on V3 :
<nic>
  <linked>false</linked>
</nic>

The vNIC network is changed to random one
Same for 'linked'
So it's probably Network issue and not storage.

Comment 1 Red Hat Bugzilla Rules Engine 2016-06-02 10:51:52 UTC
Bug tickets must have version flags set prior to targeting them to a release. Please ask maintainer to set the correct version flags and only then set the target milestone.

Comment 2 Juan Hernández 2016-06-02 11:10:49 UTC
This happens because in V4 of the API the NIC profile is mandatory, so when a request is received to add a NIC the V3 compatibility layer tries to figure out what is the right NIC profile to use. But it does it for updates as well, which isn't correct.

Comment 3 Red Hat Bugzilla Rules Engine 2016-06-02 11:10:54 UTC
This bug report has Keywords: Regression or TestBlocker.
Since no regressions or test blockers are allowed between releases, it is also being identified as a blocker for this release. Please resolve ASAP.

Comment 4 Juan Hernández 2016-06-07 21:43:17 UTC
Given that this only affects incorrect requests, I believe that it isn't a blocker.

Comment 5 Red Hat Bugzilla Rules Engine 2016-06-07 21:43:22 UTC
This bug report has Keywords: Regression or TestBlocker.
Since no regressions or test blockers are allowed between releases, it is also being identified as a blocker for this release. Please resolve ASAP.

Comment 6 Juan Hernández 2016-06-13 15:11:05 UTC
Note that comment 4 isn't accurate, this doesn't affect only incorrect requests, that comment was intended for a different bug.

Comment 7 Red Hat Bugzilla Rules Engine 2016-06-15 05:50:34 UTC
This bug report has Keywords: Regression or TestBlocker.
Since no regressions or test blockers are allowed between releases, it is also being identified as a blocker for this release. Please resolve ASAP.

Comment 8 Meni Yakove 2016-06-22 15:12:50 UTC
rhevm-4.0.0.5-0.1.el7ev.noarch

Comment 9 Sandro Bonazzola 2016-07-05 07:39:23 UTC
oVirt 4.0.0 has been released, closing current release.