This patch modified the snapshot controller flow. It works as follows:
Check the status of VolumeSnapshot object and determine the next step.
Retrieve metadata from VolumeSnapshot object if existing;
otherwise create metadata and update VolumeSnapshot object.
If metadata pre-existing, find snapshot through volume plugin;
If metadata newly created, take snapshot through volume plugin.
Create VolumeSnapshotData object with a reference to the snapshot by the plugin.
Update VolumeSnapshot object status and also bind VolumeSnapshotData to VolumeSnapshot.
Query the volume plugin for the status of the snapshot with snapshot id
from VolumeSnapshotData object until snapshot is ready.
Update VolumeSnapshot and VolumeSnapshotData.
Also added FindSnapshot (find snapshot by metadata) in the cloudprovider.
Implemented for OpenStack, not for AWS and GCE yet.
This patch modified the snapshot controller flow. It works as follows:
Also added FindSnapshot (find snapshot by metadata) in the cloudprovider. Implemented for OpenStack, not for AWS and GCE yet.