Introduce Quota resource statement API#13236
Conversation
|
@blueorangutan package |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #13236 +/- ##
==========================================
Coverage 18.10% 18.10%
- Complexity 16746 16759 +13
==========================================
Files 6037 6040 +3
Lines 542933 543141 +208
Branches 66487 66507 +20
==========================================
+ Hits 98283 98346 +63
- Misses 433602 433744 +142
- Partials 11048 11051 +3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
@blueorangutan package |
|
@DaanHoogland a [SL] Jenkins job has been kicked to build packages. It will be bundled with no SystemVM templates. I'll keep you posted as I make progress. |
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✔️ debian ✔️ suse15. SL-JID 18042 |
|
@blueorangutan test |
|
@DaanHoogland a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests |
Description
This PR introduces the
quotaResourceStatementAPI to the Quota plugin. This API allows viewing the Quota consumption associated with a specific resource. It will be used by the Quota UI rework in a separate PR.In addition, some adjustments were made in the
quotaStatementAPI in order to allow including the consumption of subdomains in the resulting statement.Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
How Has This Been Tested?
I tested the API by fuzzing its parameters for root admin, domain admin, and user accounts. In the tests, I validated that the API returned the expected response while performing correct permission checking.
Environment configuration
My environment had two domains:
ROOTandd1.Each domain had a domain admin (
drforROOTandd1ford1) and a user account (urforROOTandu1ford1).ROOTalso had a project and the root admin.Test 1 (user accounts)
id: returns the statement scoped to the owning account when the caller has access to it, and an error when it does not.accountid: returns the statement scoped to the provided account if accessible, or an empty list otherwise.projectid: returns the statement scoped to the provided project if accessible, or an exception otherwise.isrecursive: ignored for user accounts.Test 2 (domain admins)
id: returns the statement scoped to the caller's domain.accountid: returns the statement scoped to the provided account if accessible, or an exception otherwise.projectid: returns the statement scoped to the provided project if accessible, or an exception otherwise.isrecursive: allows domain admins to generate the statement including usage records of subdomains.Test 3 (root admins)
id: returns the statement of any resource without limiting.accountid: returns the statement scoped to the provided account.projectid: returns the statement scoped to the provided project.isrecursive: allows admins to generate the statement including usage records of subdomains.