Bug 1140721

Summary: UI plugin of ovirt-optimizer does not count with redirect code 302
Product: Red Hat Enterprise Virtualization Manager Reporter: Lukas Svaty <lsvaty>
Component: ovirt-optimizerAssignee: Martin Sivák <msivak>
Status: CLOSED ERRATA QA Contact: Shira Maximov <mshira>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.5.0CC: aberezin, dfediuck, mavital
Target Milestone: ---   
Target Release: 3.5.0   
Hardware: All   
OS: All   
Whiteboard: sla
Fixed In Version: vt5 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-02-11 17:37:55 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: SLA RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1156162    

Description Lukas Svaty 2014-09-11 14:14:52 UTC
Description of problem:
When clicking optimize start in VM subtab after optimizer is installed properly.
GET request is redirected to secure https. As ui plugin in index.html is only counting with 200 OK proper parsing is not done.

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

How reproducible:
100%

Steps to Reproduce:
1. Set up ovirt-optimizer
2. Click optimize-start on VM
3. 

Actual results:
GET http://10.34.63.60/ovirt-engine/api/vms [Mixed Content][HTTP/1.1 302 Moved Temporarily 6ms]

Expected results:
GET http://10.34.63.60/ovirt-engine/api/vms [Mixed Content][HTTP/1.1 302 Moved Temporarily 6ms]
Detected vm: .....

Additional info:
Code handling redirects is necessary
statusCode: {
    302: function(data) {
        // parsing
    }

Comment 1 Lukas Svaty 2014-09-12 09:57:07 UTC
it is sufficient not to force http protocol in GET

url: "/ovirt-engine/api/vms"

instead of 

url: "http://"+window.parent.location.host + "/ovirt-engine/api/vms"

in get method of index.html page of plugin

Comment 3 Lukas Svaty 2014-10-06 12:09:21 UTC
not available in current release (vt4) moving back to assigned

Comment 4 Lukas Svaty 2014-10-07 13:23:41 UTC
verified in vt5

Comment 6 errata-xmlrpc 2015-02-11 17:37:55 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.

https://rhn.redhat.com/errata/RHEA-2015-0210.html