]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Fallback to Quota Conf Driver if Quotas table is not defined
authorAkihiro MOTOKI <motoki@da.jp.nec.com>
Wed, 9 Oct 2013 10:50:35 +0000 (19:50 +0900)
committerMark McClain <mark.mcclain@dreamhost.com>
Fri, 11 Oct 2013 23:59:59 +0000 (19:59 -0400)
commit438b2ebfcd879571504359881f3881f60179e7f1
treef632266810d736c632828f0838e7ee76d57a57f5
parent1cb74d6311ee77f4349e9c1caf62593638c71f0f
Fallback to Quota Conf Driver if Quotas table is not defined

commit de15e0b9c5 enabled Quota DB driver default considering
production environments, but it breaks plugins without per-tenant
quota extension. In these plugin quotas tables is not loaded.

This commit fallbacks to ConfDriver if Quota model is not loaded by
checking neutron.db.quota_db which defines Quota model is imported.

Change-Id: Idaaaa9810598cfd3e5ce70020f498643b4819d16
Closes-Bug: #1236993
(cherry picked from commit 46495f4995b6604cb249b688aaa249ef4e8b18ef)
neutron/quota.py
neutron/tests/unit/test_quota_ext.py