Bug 1158358
| Summary: | Deactivate hosts with running vms behaves differently in SDK and REST | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Red Hat Enterprise Virtualization Manager | Reporter: | Raz Tamir <ratamir> | ||||
| Component: | ovirt-engine | Assignee: | Nobody <nobody> | ||||
| Status: | CLOSED NOTABUG | QA Contact: | |||||
| Severity: | high | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | 3.4.3 | CC: | ecohen, gklein, iheim, lpeer, lsurette, michal.skrivanek, ofrenkel, ratamir, rbalakri, Rhev-m-bugs, yeylon | ||||
| Target Milestone: | --- | ||||||
| Target Release: | --- | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | virt | ||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2014-11-19 10:06:51 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Attachments: |
|
||||||
|
Description
Raz Tamir
2014-10-29 07:57:34 UTC
Looking at the art_test_runner.log file I see that the first time, directly with the REST API, the "deactivate" action was invoked with the following XML document:
<action>
<async>false</async>
<grace_period>
<expiry>10</expiry>
</grace_period>
</action>
And the second time, with the Python SDK, it was invoked with the following XML document:
<action>
<async>false</async>
<grace_period>
<expiry>10</expiry>
</grace_period>
</action>
Exactly the same, so there is no difference between direct call and the Python SDK call, thus we can take the Python SDK out of the picture.
The RESTAPI always does the same in this case: it runs the MaintenanceNumberOfVdss action. Like this:
public Response deactivate(Action action) {
return doAction(
VdcActionType.MaintenanceNumberOfVdss,
new MaintenanceNumberOfVdssParameters(asList(guid), false),
action
);
}
There is little room there for differences between calls with the same arguments, so if there is a difference it must be in the state of the involved host, and this is managed by the backend and by VDSM, not by the RESTAPI.
this looks like a timing issue of previous test. Please check the conditions before you run the test and/or try to invoke it separately Hi Michal, What condition should I check? Of the environment. Check that the state of the host corresponds to what the test expects. I'd suspect if you run it separately/manually it will work Hi Micahl, Thanks, you were right |