]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Scope get_tenant_quotas by tenant_id
authorSalvatore Orlando <salv.orlando@gmail.com>
Mon, 12 Oct 2015 22:47:03 +0000 (15:47 -0700)
committerSalvatore Orlando <salv.orlando@gmail.com>
Wed, 13 Jan 2016 14:56:18 +0000 (14:56 +0000)
commit24b482ac15b5fa99edd2c3438318a41f9af06bcf
tree959337b206e4029c9b81bf7a9fe4f731cf8b941e
parent6576b7061ea4c4068246bbd01f605a12e689c2c6
Scope get_tenant_quotas by tenant_id

Using model_query in the operation for retrieving tenant limits
will spare the need for explicit authorization check in the
quota controller. This is particularly relevant for the pecan
framework where every Neutron API call undergoes authZ checks
in the same pecan hook.

This patch will automatically adapt by eventuals changes
introducing "un-scoped" contexts.

Closes-bug: #1505406

Change-Id: I6952f5c85cd7fb0263789f768d23de3fe80b8183
neutron/db/quota/driver.py
neutron/tests/unit/db/quota/test_driver.py