Support explicit authorization

Bug #1513200 reported by Brian Curtin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack SDK
Fix Committed
High
Unassigned

Bug Description

We currently take credentials in the Connection but don't do anything with them until you try to do anything. We should probably support something like an `authorize` method on Connection that either succeeds or fails there, instead of applications breaking down at potentially odd spots for somewhat unrelated reasons (think of a create_container failing just for bad credentials, the failure isn't *really* tied to create_container)

This wouldn't be required -- we'd still go grab a token on the first request if you're not already authorized -- but it can be nice to know even earlier than your first call whether or not the app is going to work.

Tags: auth session
tags: added: auth session
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-openstacksdk (master)

Reviewed: https://review.openstack.org/242681
Committed: https://git.openstack.org/cgit/openstack/python-openstacksdk/commit/?id=0ed87c2cc17d24e123864a58bae2841ca49ce155
Submitter: Jenkins
Branch: master

commit 0ed87c2cc17d24e123864a58bae2841ca49ce155
Author: Brian Curtin <email address hidden>
Date: Fri Nov 6 16:49:43 2015 -0600

    Add authorize method to Connection

    The ability to know your application is going to fail due to a
    credential issue *before* getting into the application and attempting to
    make some API call can be useful. This change adds Connection.authorize,
    which just does the same thing we do implicitly. It's entirely optional
    and is documented as such.

    Co-Authored-By: Qiming Teng (<email address hidden>)
    Closes-Bug: #1513200
    Change-Id: If86f308da909c4ff31f37294a000c6972c947182

Changed in python-openstacksdk:
status: Confirmed → Fix Committed
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.