Save off the UUID of the VDI before detaching its SR

This commit is contained in:
Mike Tutkowski 2014-10-20 16:44:34 -06:00
parent 15c8d8caf6
commit b1ffd88a42
1 changed files with 3 additions and 1 deletions

View File

@ -135,6 +135,8 @@ public class XenServerStorageProcessor implements StorageProcessor {
VDI vdiCopy = vdiSnapshot.copy(conn, newSr);
String vdiUuid = vdiCopy.getUuid(conn);
vdiSnapshot.destroy(conn);
if (sourceSr != null) {
@ -145,7 +147,7 @@ public class XenServerStorageProcessor implements StorageProcessor {
SnapshotAndCopyAnswer snapshotAndCopyAnswer = new SnapshotAndCopyAnswer();
snapshotAndCopyAnswer.setPath(vdiCopy.getUuid(conn));
snapshotAndCopyAnswer.setPath(vdiUuid);
return snapshotAndCopyAnswer;
}