Bases: dict
Bases: CinderCleanableObject
, CinderObject
, CinderObjectDictCompat
, CinderComparableObject
, ClusteredObject
Get volume’s latest snapshot
alias of Volume
Actual volume’s UUID for driver usage.
There may be two different UUIDs for the same volume, the user facing one, and the one the driver should be using.
When a volume is created these two are the same, but when doing a generic migration (create new volume, then copying data) they will be different if we were unable to rename the new volume in the final migration steps.
So the volume will have been created using the new volume’s UUID and the driver will have to look for it using that UUID, but the user on the other hand will keep referencing the volume with the original UUID.
This property facilitates using the right UUID in the driver’s code.
Load an additional attribute from the real object.
This should load self.$attrname and cache any data that might be useful for future load operations.
Make a Volume representation compatible with a target version.
Reset the list of fields that have been changed.
fields – List of fields to reset, or “all” if None.
recursive – Call obj_reset_changes(recursive=True) on any sub-objects within the list of fields being reset.
This is NOT “revert to previous values”.
Specifying fields on recursive resets will only be honored at the top level. Everything below the top will reset all.
Returns a set of fields that have been modified.
Populate CG fields based on group fields.
Method assumes that consistencygroup_id and consistencygroup fields have not already been set.
This is a hack to support backward compatibility of consistencygroup, where we set the fields but don’t want to write them to the DB, so we mark them as not changed, so they won’t be stored on the next save().
Save the changed fields back to the store.
This is optional for subclasses, but is presented here in the base class for consistency among those that do.
Bases: ObjectListBase
, CinderObject
Include all volumes matching the filters into a cluster.
When partial_rename is set we will not set the cluster_name with cluster parameter value directly, we’ll replace provided cluster_name or host filter value with cluster instead.
This is useful when we want to replace just the cluster name but leave the backend and pool information as it is. If we are using cluster_name to filter, we’ll use that same DB field to replace the cluster value and leave the rest as it is. Likewise if we use the host to filter.
Returns the number of volumes that have been changed.
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.