-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
None
Description of problem:
It is possible to successfully create quota entry with any text word instead of valid project ID. This is misleading for customers: they successfully create quotas with project names instead of project IDs, but those quotas are not enforced.
How reproducible:
The following command may look like a command that adds a quota for admin tenant, but instead it creates a dummy record in cinder DB:
cinder quota-update --volumes 3 admin
MariaDB [cinder]> SELECT * FROM quotas WHERE project_id="admin";
---------------------------------------------------------------------------------------
| id | created_at | updated_at | deleted_at | deleted | project_id | resource | hard_limit | allocated |
---------------------------------------------------------------------------------------
| 6 | 2018-05-03 09:41:49 | NULL | NULL | 0 | admin | volumes | 3 | 0 |
---------------------------------------------------------------------------------------
Here is an entry for valid cinder quota:
MariaDB [cinder]> SELECT * FROM quotas WHERE project_id="602c2a16e060483f997193a314d0b9c7" AND resource="volumes";
----------------------------------------------------------------------------------------------------------------------
| id | created_at | updated_at | deleted_at | deleted | project_id | resource | hard_limit | allocated |
----------------------------------------------------------------------------------------------------------------------
| 9 | 2018-05-03 10:02:00 | 2018-05-03 10:09:06 | NULL | 0 | 602c2a16e060483f997193a314d0b9c7 | volumes | 9 | 0 |
----------------------------------------------------------------------------------------------------------------------
Actual results:
cinder creates misleading quota entries in DB
Expected results:
cinder asks to use valid project_id
- external trackers