]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commit
Split out NestedQuotas into a separate driver
authorRyan McNair <rdmcnair@us.ibm.com>
Sat, 30 Jan 2016 16:24:32 +0000 (16:24 +0000)
committerRyan McNair <rdmcnair@us.ibm.com>
Wed, 17 Feb 2016 22:30:00 +0000 (22:30 +0000)
commit7ebd4904b977d29c97447b53fbd718bccfa39969
tree214ac1ef6ee97d5a721dcbf1b18a08b8a2e6bb30
parentc9457d14522e47a992311ecad2beab569c67bf94
Split out NestedQuotas into a separate driver

Fixes the following issues with NestedQuotas:
  * Requires conf setting change to use nested quota driver
  * Enforces default child quota value with volume creation
  * Disables the use of -1 to be set for child quotas
  * Adds an admin only API command which can be used to validate
    the current setup for nested quotas, and can update existing
    allocated quotas in the DB which have been incorrectly set
    by previous use of child limits with -1

There will be follow-up patches with the following improvements:
  * make -1 limits functional for child projects
  * cache the Keystone project heirarchies to improve efficiency

Note: ideally validation of nested quotas would occur in the setup
of the nested quota driver, but doing the validation requires a
view of ALL projects present in Keystone, so unless we require Keystone
change to allow "cinder" service user to be able to list/get projects,
we need the admin-only API for validation that should be called by
cloud-admin.

DocImpact

Change-Id: Ibbd6f47c370d8f10c08cba358574b55e3059dcd1
Closes-Bug: #1531502
Partial-Bug: #1537189
Related-Bug: #1535878
cinder/api/contrib/quotas.py
cinder/exception.py
cinder/quota.py
cinder/quota_utils.py
cinder/tests/unit/api/contrib/test_quotas.py
cinder/tests/unit/test_quota.py
cinder/tests/unit/test_quota_utils.py [new file with mode: 0644]
etc/cinder/policy.json
releasenotes/notes/split-out-nested-quota-driver-e9493f478d2b8be5.yaml [new file with mode: 0644]