11 Commits

Author SHA1 Message Date
Monty Taylor
1a0b7b0a64 Code cleanup in advance of flake8.
Change-Id: Ia2b463fdf3092aa72147eeda41faad4733fddd46
2013-05-25 08:22:39 +02:00
Roman Podolyaka
27e904af69 Use HTTP keep-alive feature in HTTPClient class
Currently  HTTPClient creates a new TCP connection for each
API request. We could actually reuse created connections by
relying upon HTTP keep-alive feature.  That would enable us
to do a few queries in a row more efficiently.

Fixes bug 1170385.

Change-Id: Ie6d8fb9670938e3790017509a242630b67abd794
2013-04-19 09:46:17 +03:00
Alvaro Lopez Garcia
abd75f24b1 Improve authentication plugins management.
The current auth plugin system lacks some functionality to be used with
other methods that might require additional configuration options or
that do not require a user to pass some options that are now compulsory
(for example, X.509 authentication needs to get a certificate file, and
does not need either a username or a password). This commit extends
the current system to handle these extra features, while remaining
compatible with older plugins.

DocImpact: We should documment how to implement additional
authentication plugins, such as BasicAuth, X509, etc.
Implements: blueprint authentication-plugins

Change-Id: I7b0ef4981efba8160dea94bf852dba7e2e4068f5
2013-04-01 14:19:01 +00:00
Davanum Srinivas
c5b579926f Fix Copyright Headers from LLC to Foundation
follow the lead from nova and oslo projects

Change-Id: I270c5f1e4eefa4b72e292bfb4a4c60de0c3f6e4a
2013-03-13 20:12:23 -04:00
Vishvananda Ishaya
1e4a778bf8 Store tenant_id from keystone and use for quotas
Some calls in nova require a tenant_id when it could be interpreted
from the current authentication data, so save the tenant id and
use it in the quotas command if tenant_id is not specified.

Change-Id: I89647cfe9da73bc474ef80a61a5678db42a5571c
2013-01-31 14:38:21 -08:00
Monty Taylor
53aee5cf4b Move from untitest2 to testtools.
Use testtools as the base testclass. Use fixtures library for managing
fixtures.

Part of blueprint grizzly-testtools

Change-Id: Iac5af286b988787acf7049344641aadf140b9398
2013-01-03 11:58:13 -08:00
Dean Troyer
aa1df04bad Use requests module for HTTP/HTTPS
* Implement correct certificate verification
* Add --os-cacert
* Rework tests for requests

Pinned requests module to < 1.0 as 1.0.2 is now current in pipi
as of 17Dec2012.

Blueprint: tls-verify

Change-Id: I9a25a94c8dfcaf483c4c8328439809d65cf10b38
2012-12-20 13:04:46 -06:00
Dan Prince
e483455a12 Adds --os-cache to replace old --no-cache.
Deprecates the old --no-cache option in favor of --os-cache.

The old CLI args (--no_cache and --no-cache) and ENV option
(OS_NO_CACHE) are still supported but no longer show up
in help.

The new option for --os-cache can also be set via the OS_CACHE ENV
variable... which now defaults to False. This should be much more user friendly.

Fixes LP Bug #1087776.

Change-Id: I3cea089c7e11ce75f22c2d7f3242b02b80441323
2012-12-11 12:58:37 -05:00
Josh Kearney
2f7b032910 Pull in latest openstack-common changes and fix a minor PEP8 issue.
Latest openstack-common commit: d887090b5a31672e4a12f302b3818e2b0933bef0

Change-Id: I5a4ffb043ab24f8618a8285112c0c5992ea129e7
2012-10-25 11:48:15 -05:00
Stef T
a9a66ae7a7 Raises Exception on improper Auth Configuration
Addresses bug 1061848.

Basically, this bug comes about from not properly
setting up the auth_system for novaclient. In this
case, an exception of EndPointNotFound is flung.

Change-Id: I12533aefd9d0425dd83e2e4c63f4dd5ff6faae71
2012-10-04 16:33:27 -04:00
Chmouel Boudjnah
86c713b17a Allow different auth providers via plugin system.
- Remove the NOVA_RAX_AUTH hack and provide (temporary) compatibility
  with the new system.
- Example plugin for RAX and HP provided here :
    RAX - https://github.com/emonty/rackspace-auth-openstack
    HP - https://github.com/emonty/hpcloud-auth-openstack
- Plugin are allowed to specify their own auth_url directly.
- Thanks to mtaylor for helping on this.

Change-Id: Ie96835be617c6a20d9c3fc3bd1536083aecfdc0b
2012-08-06 09:10:00 +02:00