Bug 915036

Summary: REST-API : server replies in yaml instead of xml on GET: /api/vms/xxx/reporteddevices
Product: Red Hat Enterprise Virtualization Manager Reporter: Oded Ramraz <oramraz>
Component: ovirt-engine-restapiAssignee: Ravi Nori <rnori>
Status: CLOSED ERRATA QA Contact: Oded Ramraz <oramraz>
Severity: medium Docs Contact:
Priority: high    
Version: unspecifiedCC: acathrow, bazulay, dyasny, iheim, mpastern, oramraz, Rhev-m-bugs, sgrinber, yeylon, ykaul
Target Milestone: ---   
Target Release: 3.2.0   
Hardware: Unspecified   
OS: Linux   
Whiteboard: infra
Fixed In Version: Doc Type: Bug Fix
Doc Text:
--no tech note required
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-06-10 21:49:01 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:    
Bug Blocks: 948448    

Description Oded Ramraz 2013-02-24 11:00:33 UTC
Description of problem:

Error while trying to retrieve host hooks using rhevm-shell ( see Additional Information ) 


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


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

[RHEVM shell (connected)]# list hosts 

id         : 406f6a01-ba83-4393-b919-382fec63ba4c                               
name       : aqua-vds4                                                          

id         : 75fc4763-1c86-4ed1-a575-154e41133030                               
name       : aqua-vds5                                                          

[RHEVM shell (connected)]# list hooks --host-identifier "75fc4763-1c86-4ed1-a575-154e41133030"

error: Start tag expected, '<' not found, line 1, column 1

Comment 1 Oded Ramraz 2013-02-24 11:01:30 UTC
rhevm-sdk-3.2.0.2-1.el6ev.noarch

Comment 2 Michael Pasternak 2013-02-24 11:03:39 UTC
caused by not up to date python2xml bindings, will be automatically fixed
at next drop rhevm-sdk-3.2.0.4.

Comment 3 Oded Ramraz 2013-02-24 11:27:36 UTC
Same error for reported devices: 

[RHEVM shell (connected)]# list reporteddevices  --vm-identifier 6c10ba4d-65b1-4738-a62a-e2321976d733

error: Start tag expected, '<' not found, line 1, column 1

Comment 4 Michael Pasternak 2013-02-24 11:39:04 UTC
well, this is api bug after all and not related to sdk bindings state, mentioned collections ignoring 'Content-type': 'application/xml', and replying in yaml instead of xml:

GET: /api/vms/bae984c7-2697-46b7-8a98-01cb6e9e38f9/reporteddevices

str: !!org.ovirt.engine.api.model.ReportedDevices {actions: null, active: null, total: null}

Comment 5 Michael Pasternak 2013-02-24 11:45:32 UTC
[mpastern@lpt21 ~]$ curl -X GET -u admin@internal:$PASS http://localhost:8080/api/vms/bae984c7-2697-46b7-8a98-01cb6e9e38f9/reporteddevices

!!org.ovirt.engine.api.model.ReportedDevices {actions: null, active: null, total: null}

Comment 8 Michael Pasternak 2013-03-04 12:05:15 UTC
this bug is not a regression since this is 2.2 feature.

Comment 10 Oded Ramraz 2013-03-12 20:16:11 UTC
Verified sf10 , both reportdevices and hooks are retrieved without any errors . 
(Although I'm not sure if reportdevices is a good name , maybe need to open separate bug )

Comment 11 Cheryn Tan 2013-04-03 06:53:47 UTC
This bug is currently attached to errata RHEA-2013:14491. If this change is not to be documented in the text for this errata please either remove it from the errata, set the requires_doc_text flag to minus (-), or leave a "Doc Text" value of "--no tech note required" if you do not have permission to alter the flag.

Otherwise to aid in the development of relevant and accurate release documentation, please fill out the "Doc Text" field above with these four (4) pieces of information:

* Cause: What actions or circumstances cause this bug to present.

* Consequence: What happens when the bug presents.

* Fix: What was done to fix the bug.

* Result: What now happens when the actions or circumstances above occur. (NB: this is not the same as 'the bug doesn't present anymore')

Once filled out, please set the "Doc Type" field to the appropriate value for the type of change made and submit your edits to the bug.

For further details on the Cause, Consequence, Fix, Result format please refer to:

https://bugzilla.redhat.com/page.cgi?id=fields.html#cf_release_notes

Thanks in advance.

Comment 12 errata-xmlrpc 2013-06-10 21:49:01 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

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

http://rhn.redhat.com/errata/RHSA-2013-0888.html