Quotas for volumes.
Bases: cinder.quota.BaseResource
Describe a non-reservable resource.
Bases: object
Describe a single resource for quota checking.
Return the default value of the quota.
Given a driver and context, obtain the quota for this resource.
Parameters: |
|
---|
Bases: cinder.quota.QuotaEngine
Represent the consistencygroup quotas.
Fetches all possible quota resources.
Bases: cinder.quota.AbsoluteResource
Describe a resource where counts aren’t based only on the project ID.
Bases: object
Driver to perform check to enforcement of quotas.
Also allows to obtain quota information. The default driver utilizes the local database.
Commit reservations.
Parameters: |
|
---|
Destroy all limit quotas associated with a project.
Leave usage and reservation quotas intact.
Parameters: |
|
---|
Expire reservations.
Explores all currently existing reservations and rolls back any that have expired.
Parameters: | context – The request context, for access checks. |
---|
Get a specific quota by quota class.
Get a specific quota by project.
Given list of resources, retrieve the quotas for given quota class.
Parameters: |
|
---|
Get a specific default quota for a resource.
Given a list of resources, retrieve the default quotas.
Use the class quotas named _DEFAULT_QUOTA_NAME as default quotas, if it exists.
Parameters: |
|
---|
Retrieve quotas for a project.
Given a list of resources, retrieve the quotas for the given project.
Parameters: |
|
---|
Check simple quota limits.
For limits–those quotas for which there is no usage synchronization function–this method checks that a set of proposed values are permitted by the limit restriction.
This method will raise a QuotaResourceUnknown exception if a given resource is unknown or if it is not a simple limit resource.
If any of the proposed values is over the defined quota, an OverQuota exception will be raised with the sorted list of the resources which are too high. Otherwise, the method returns nothing.
Parameters: |
|
---|
Check quotas and reserve resources.
For counting quotas–those quotas for which there is a usage synchronization function–this method checks quotas against current usage and the desired deltas.
This method will raise a QuotaResourceUnknown exception if a given resource is unknown or if it does not have a usage synchronization function.
If any of the proposed values is over the defined quota, an OverQuota exception will be raised with the sorted list of the resources which are too high. Otherwise, the method returns a list of reservation UUIDs which were created.
Parameters: |
|
---|
Roll back reservations.
Parameters: |
|
---|
Bases: cinder.quota.DbQuotaDriver
Get a specific default quota for a resource.
Ensures project_tree has quotas that make sense as nested quotas.
Bases: object
Represent the set of recognized quotas.
Add volume type resource options.
Adds elements to the opts hash for volume type quotas. If a resource is being reserved (‘gigabytes’, etc) and the volume type is set up for its own quotas, these reservations are copied into keys for ‘gigabytes_<volume type name>’, etc.
Parameters: |
|
---|
Commit reservations.
Parameters: |
|
---|
Count a resource.
For countable resources, invokes the count() function and returns its result. Arguments following the context and resource are passed directly to the count function declared by the resource.
Parameters: |
|
---|
Destroy all quota limits associated with a project.
Parameters: |
|
---|
Expire reservations.
Explores all currently existing reservations and rolls back any that have expired.
Parameters: | context – The request context, for access checks. |
---|
Get a specific quota by quota class.
Get a specific quota by project.
Get specific quota by project or default quota if doesn’t exists.
Retrieve the quotas for the given quota class.
Parameters: |
|
---|
Get a specific default quota for a resource.
Parameters: | parent_project_id – The id of the current project’s parent, if any. |
---|
Retrieve the default quotas.
Parameters: |
|
---|
Retrieve the quotas for the given project.
Parameters: |
|
---|
Check simple quota limits.
For limits–those quotas for which there is no usage synchronization function–this method checks that a set of proposed values are permitted by the limit restriction. The values to check are given as keyword arguments, where the key identifies the specific quota limit to check, and the value is the proposed value.
This method will raise a QuotaResourceUnknown exception if a given resource is unknown or if it is not a simple limit resource.
If any of the proposed values is over the defined quota, an OverQuota exception will be raised with the sorted list of the resources which are too high. Otherwise, the method returns nothing.
Parameters: |
|
---|
Register a resource.
Register a list of resources.
Check quotas and reserve resources.
For counting quotas–those quotas for which there is a usage synchronization function–this method checks quotas against current usage and the desired deltas. The deltas are given as keyword arguments, and current usage and other reservations are factored into the quota check.
This method will raise a QuotaResourceUnknown exception if a given resource is unknown or if it does not have a usage synchronization function.
If any of the proposed values is over the defined quota, an OverQuota exception will be raised with the sorted list of the resources which are too high. Otherwise, the method returns a list of reservation UUIDs which were created.
Parameters: |
|
---|
Roll back reservations.
Parameters: |
|
---|
Returns true if nested quotas are being used
Bases: cinder.quota.BaseResource
Describe a reservable resource.
Bases: cinder.quota.QuotaEngine
Represent the set of all quotas.
Fetches all possible quota resources.
Update resource in quota.
This is to update resource in quotas, quota_classes, and quota_usages once the name of a volume type is changed.
Parameters: |
|
---|
Bases: cinder.quota.ReservableResource
ReservableResource for a specific volume type.