Maor Lipchuk has uploaded a new change for review.

Change subject: core: Add API to create Cinder snapshot.
......................................................................

core: Add API to create Cinder snapshot.

Add API for Cinder snapshot creation.

Change-Id: I637b3a0ceacefdf0d85f49d9da9344c3de9b8b70
Bug-Url: https://bugzilla.redhat.com/1185826
Signed-off-by: Maor Lipchuk <[email protected]>
---
M 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/storage/OpenStackVolumeProviderProxy.java
1 file changed, 7 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/54/40554/1

diff --git 
a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/storage/OpenStackVolumeProviderProxy.java
 
b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/storage/OpenStackVolumeProviderProxy.java
index 3af47a3..2f86a20 100644
--- 
a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/storage/OpenStackVolumeProviderProxy.java
+++ 
b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/storage/OpenStackVolumeProviderProxy.java
@@ -5,6 +5,8 @@
 import com.woorea.openstack.cinder.model.ConnectionForInitialize;
 import com.woorea.openstack.cinder.model.ConnectionInfo;
 import com.woorea.openstack.cinder.model.Limits;
+import com.woorea.openstack.cinder.model.SnapshotForCreate;
+import com.woorea.openstack.cinder.model.Snapshot;
 import com.woorea.openstack.cinder.model.Volume;
 import com.woorea.openstack.cinder.model.VolumeForCreate;
 import com.woorea.openstack.cinder.model.VolumeForUpdate;
@@ -67,6 +69,11 @@
         return client;
     }
 
+    public String createSnapshot(SnapshotForCreate snapshotForCreate) {
+        Snapshot retCinderSnapshot = 
getClient(getTenantId()).snapshots().create(snapshotForCreate).execute();
+        return retCinderSnapshot.getId();
+    }
+
     public String createVolume(VolumeForCreate volumeForCreate) {
         Volume retCinderVolume = 
getClient(getTenantId()).volumes().create(volumeForCreate).execute();
         return retCinderVolume.getId();


-- 
To view, visit https://gerrit.ovirt.org/40554
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I637b3a0ceacefdf0d85f49d9da9344c3de9b8b70
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Maor Lipchuk <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to