ceilometerclient insecure argument no longer works

Bug #1438750 reported by Matthew Edmonds
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
python-ceilometerclient
Fix Released
Undecided
Matthew Edmonds

Bug Description

with ceilometerclient 1.0.13 the os_insecure argument is no longer handled properly for ceilometerclient.client.get_client(), as seen below:

>>> from ceilometerclient import client as ceilo_client
>>> args = {'os_service_type': 'metering', 'os_insecure': 'True', 'os_auth_url': 'https://127.0.0.1:5000', 'os_project_domain_name': 'Default', 'os_tenant_name': 'myproject', 'os_user_domain_name': 'Default', 'os_username': 'myuser', 'os_password': 'mypassw0rd'}
>>> c = ceilo_client.get_client('2', **args)
>>> c.meters.list()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/site-packages/ceilometerclient/v2/meters.py", line 30, in list
    return self._list(options.build_url(path, q))
  File "/usr/lib/python2.7/site-packages/ceilometerclient/common/base.py", line 68, in _list
    resp = self.api.get(url)
  File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/client.py", line 355, in get
    return self.client_request("GET", url, **kwargs)
  File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/client.py", line 345, in client_request
    self, method, url, **kwargs)
  File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/client.py", line 244, in client_request
    self.authenticate()
  File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/client.py", line 315, in authenticate
    self.auth_plugin.authenticate(self)
  File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/auth.py", line 203, in authenticate
    self._do_authenticate(http_client)
  File "/usr/lib/python2.7/site-packages/ceilometerclient/client.py", line 192, in _do_authenticate
    ks_session = _get_keystone_session(**ks_kwargs)
  File "/usr/lib/python2.7/site-packages/ceilometerclient/client.py", line 84, in _get_keystone_session
    v2_auth_url, v3_auth_url = _discover_auth_versions(ks_session, auth_url)
  File "/usr/lib/python2.7/site-packages/ceilometerclient/client.py", line 33, in _discover_auth_versions
    ks_discover = discover.Discover(session=session, auth_url=auth_url)
  File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 318, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/discover.py", line 166, in __init__
    authenticated=authenticated)
  File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 318, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/_discover.py", line 142, in __init__
    authenticated=authenticated)
  File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 318, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/_discover.py", line 40, in get_version_data
    resp = session.get(url, headers=headers, authenticated=authenticated)
  File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 478, in get
    return self.request(url, 'GET', **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 318, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 370, in request
    resp = send(**kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 409, in _send_request
    raise exceptions.SSLError(msg)
keystoneclient.exceptions.SSLError: SSL exception connecting to https://127.0.0.1:5000

Changed in ceilometer:
assignee: nobody → Matthew Edmonds (edmondsw)
Changed in ceilometer:
status: New → In Progress
gordon chung (chungg)
affects: ceilometer → python-ceilometerclient
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-ceilometerclient (master)

Fix proposed to branch: master
Review: https://review.openstack.org/169442

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-ceilometerclient (master)

Reviewed: https://review.openstack.org/169442
Committed: https://git.openstack.org/cgit/openstack/python-ceilometerclient/commit/?id=a5df77d8730284e278fde087e8bb3c2520c6ddb1
Submitter: Jenkins
Branch: master

commit a5df77d8730284e278fde087e8bb3c2520c6ddb1
Author: Matthew Edmonds <email address hidden>
Date: Tue Mar 31 09:53:15 2015 -0400

    ceilometerclient insecure argument no longer works

    The os_insecure argument needs to be parsed and passed to the auth
    plugin for non-shell usage.

    Change-Id: Id45a680396a9b646b273d971a0f6c274e95019a6
    Closes-Bug: #1438750

Changed in python-ceilometerclient:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-ceilometerclient (stable/kilo)

Fix proposed to branch: stable/kilo
Review: https://review.openstack.org/175510

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-ceilometerclient (stable/kilo)

Reviewed: https://review.openstack.org/175510
Committed: https://git.openstack.org/cgit/openstack/python-ceilometerclient/commit/?id=7d7e4b878215c609653989a1ab5e9257b34ee5c6
Submitter: Jenkins
Branch: stable/kilo

commit 7d7e4b878215c609653989a1ab5e9257b34ee5c6
Author: Matthew Edmonds <email address hidden>
Date: Tue Mar 31 09:53:15 2015 -0400

    ceilometerclient insecure argument no longer works

    The os_insecure argument needs to be parsed and passed to the auth
    plugin for non-shell usage.

    Change-Id: Id45a680396a9b646b273d971a0f6c274e95019a6
    Closes-Bug: #1438750
    (cherry picked from commit a5df77d8730284e278fde087e8bb3c2520c6ddb1)

tags: added: in-stable-kilo
Changed in python-ceilometerclient:
milestone: none → 1.3.0
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.