openstack.block_store.v2.snapshot

The Snapshot Class

The Snapshot class inherits from Resource.

class openstack.block_store.v2.snapshot.Snapshot(attrs=None, loaded=False)

Construct a Resource to interact with a service’s REST API.

The Resource class offers two class methods to construct resource objects, which are preferrable to entering through this initializer. See Resource.new() and Resource.existing().

Parameters:
  • attrs (dict) – The attributes to set when constructing this Resource.
  • loaded (bool) – True if this Resource exists on the server, False if it does not.
id = None

A ID representing this snapshot.

name = None

Name of the snapshot. Default is None.

status = None

The current status of this snapshot. Potential values are creating, available, deleting, error, and error_deleting.

description = None

Description of snapshot. Default is None.

created_at = None

The timestamp of this snapshot creation. Type: datetime object parsed from ISO 8601 formatted string

metadata = None

Metadata associated with this snapshot.

volume_id = None

The ID of the volume this snapshot was taken of.

size = None

The size of the volume, in GBs.

is_forced = None

Indicate whether to create snapshot, even if the volume is attached. Default is False. Type: bool

The SnapshotDetail Class

The SnapshotDetail class inherits from Snapshot.

class openstack.block_store.v2.snapshot.SnapshotDetail(attrs=None, loaded=False)

Construct a Resource to interact with a service’s REST API.

The Resource class offers two class methods to construct resource objects, which are preferrable to entering through this initializer. See Resource.new() and Resource.existing().

Parameters:
  • attrs (dict) – The attributes to set when constructing this Resource.
  • loaded (bool) – True if this Resource exists on the server, False if it does not.
progress = None

The percentage of completeness the snapshot is currently at.

project_id = None

The project ID this snapshot is associated with.