diff options
| author | Vladimir Eremin <yottatsa@yandex-team.ru> | 2015-01-15 13:11:30 +0300 |
|---|---|---|
| committer | Vladimir Eremin <yottatsa@yandex-team.ru> | 2015-01-15 10:33:39 +0000 |
| commit | 3296781b2c890a700507f26789d6f3cc5f126f35 (patch) | |
| tree | 8865ea6b7d81b6ccdcecfa47a58466f6b1666724 /openstackclient/network | |
| parent | 8dd8cdcdfebd0ad26bd3ddba8b6e75d1793d290b (diff) | |
| download | python-openstackclient-3296781b2c890a700507f26789d6f3cc5f126f35.tar.gz | |
Use session for neutron client
python-openstack client is now using sessions to create clients. This
patch implements creating Network client using sessions.
Related to c3c6edbe8a083aef0fb6aea3cb461ff8e715fc59
Change-Id: If90ac705eb11dfc1e3abbe2ce18c3d8ccefdbdfb
Closes-Bug: 1411179
Diffstat (limited to 'openstackclient/network')
| -rw-r--r-- | openstackclient/network/client.py | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/openstackclient/network/client.py b/openstackclient/network/client.py index bb3e1b23..858a5079 100644 --- a/openstackclient/network/client.py +++ b/openstackclient/network/client.py @@ -34,21 +34,9 @@ def make_client(instance): API_VERSIONS) LOG.debug('Instantiating network client: %s', network_client) - endpoint = instance.get_endpoint_for_service_type( - API_NAME, - region_name=instance._region_name, - ) - return network_client( - username=instance._username, - tenant_name=instance._project_name, - password=instance._password, + session=instance.session, region_name=instance._region_name, - auth_url=instance._auth_url, - endpoint_url=endpoint, - token=instance.auth.get_token(instance.session), - insecure=instance._insecure, - ca_cert=instance._cacert, ) |
