summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZuul <zuul@review.openstack.org>2018-12-17 10:30:29 +0000
committerGerrit Code Review <review@openstack.org>2018-12-17 10:30:29 +0000
commitca24b503f814fbad6ddb3aa601f05a0e5f311e87 (patch)
tree2c7c1d04fc5cd177db6363b21771c728322c86e4
parentc17db9f29542c38709d7e026aefc44ac1134bbcd (diff)
parent9cbdfb2181f1d0acb303214deeee781f57ba48d9 (diff)
downloadpython-neutronclient-ca24b503f814fbad6ddb3aa601f05a0e5f311e87.tar.gz
Merge "Add support for querying quotas with usage"
-rw-r--r--neutronclient/v2_0/client.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/neutronclient/v2_0/client.py b/neutronclient/v2_0/client.py
index 2c0d88e..560b531 100644
--- a/neutronclient/v2_0/client.py
+++ b/neutronclient/v2_0/client.py
@@ -501,6 +501,7 @@ class Client(ClientBase):
quotas_path = "/quotas"
quota_path = "/quotas/%s"
quota_default_path = "/quotas/%s/default"
+ quota_details_path = "/quotas/%s/details.json"
extensions_path = "/extensions"
extension_path = "/extensions/%s"
routers_path = "/routers"
@@ -755,6 +756,13 @@ class Client(ClientBase):
@debtcollector.renames.renamed_kwarg(
'tenant_id', 'project_id', replace=True)
+ def show_quota_details(self, project_id, **_params):
+ """Fetch information of a certain project's quota details."""
+ return self.get(self.quota_details_path % (project_id),
+ params=_params)
+
+ @debtcollector.renames.renamed_kwarg(
+ 'tenant_id', 'project_id', replace=True)
def show_quota_default(self, project_id, **_params):
"""Fetch information of a certain project's default quotas."""
return self.get(self.quota_default_path % (project_id), params=_params)