Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update rhevm api uri to support 4.0 #62

Merged
merged 1 commit into from
Aug 31, 2016
Merged

Conversation

amavinag
Copy link
Contributor

@amavinag amavinag commented Aug 31, 2016

the rhevm api uri needs to include 'ovirt-engine' for version 4.0. so the uri would look like: https://rhevmip/ovirt-engine/api before it used to be https://rhevmip/api

  • appended 'ovirt-engine' to rhevm api uri.

@dajoRH dajoRH added the lint-ok label Aug 31, 2016
@@ -95,6 +95,10 @@ def __init__(self, hostname, username, password, **kwargs):
else:
url = 'https://%s/api' % hostname

if 'version' in kwargs:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is more to it than this I think, the RHEVM API has moved, we will need to investigate this. Does the old client API support 4.0? We froze the requirement for ovirtsdk to get around it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's probably cleaner to do this

            url_component = 'ovirt-engine/api' if float(kwargs['version']) >= 4.0 else 'api'
            if 'port' in kwargs:
                url = 'https://{}:{}/{}'.format(hostname, kwargs['port'], url_component)
            else:
                url = 'https://{}/{}'.format(hostname, url_component)

  * appended 'ovirt-engine' to rhevm api uri.
@dajoRH
Copy link
Contributor

dajoRH commented Aug 31, 2016

Lint report for commit dcff0e5:

Everything seems all right from lint perspective 😄 .

Commit inspection report:
No commit flaws detected.

CFME QE Bot

@psav psav merged commit ac2c8c3 into RedHatQE:master Aug 31, 2016
@mfalesni
Copy link
Contributor

mfalesni commented Sep 1, 2016

PR #60 adressed this and it only requires an additional entry in the yaml (api_endpoint) :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants