summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/main/java/org/openslx/virtualization/configuration/VirtualizationConfiguration.java14
-rw-r--r--src/main/java/org/openslx/virtualization/configuration/VirtualizationConfigurationVmware.java7
2 files changed, 17 insertions, 4 deletions
diff --git a/src/main/java/org/openslx/virtualization/configuration/VirtualizationConfiguration.java b/src/main/java/org/openslx/virtualization/configuration/VirtualizationConfiguration.java
index d4b3058..f548597 100644
--- a/src/main/java/org/openslx/virtualization/configuration/VirtualizationConfiguration.java
+++ b/src/main/java/org/openslx/virtualization/configuration/VirtualizationConfiguration.java
@@ -129,14 +129,22 @@ public abstract class VirtualizationConfiguration
return displayName;
}
- /*
- * Getter for isMachineSnapshot
- */
public boolean isMachineSnapshot()
{
return isMachineSnapshot;
}
+ /**
+ * Return name of file that indicates this VM is currently suspended.
+ * The existence of this file means the VM is currently suspended.
+ * Can be null if this virtualizer doesn't support suspension, or if
+ * it's already known the VM is not in a suspended state.
+ */
+ public String getSuspendedFile()
+ {
+ return null;
+ }
+
private class VersionOption extends VirtOptionValue {
private final Version version;
diff --git a/src/main/java/org/openslx/virtualization/configuration/VirtualizationConfigurationVmware.java b/src/main/java/org/openslx/virtualization/configuration/VirtualizationConfigurationVmware.java
index a237674..107014f 100644
--- a/src/main/java/org/openslx/virtualization/configuration/VirtualizationConfigurationVmware.java
+++ b/src/main/java/org/openslx/virtualization/configuration/VirtualizationConfigurationVmware.java
@@ -139,7 +139,6 @@ public class VirtualizationConfigurationVmware extends VirtualizationConfigurati
removeEntriesStartingWith( controllerType + ":" + deviceId + "." );
}
}
- // TODO check if this machine is in a paused/suspended state
this.isMachineSnapshot = false;
// Add HDD to cleaned vmx
@@ -733,4 +732,10 @@ public class VirtualizationConfigurationVmware extends VirtualizationConfigurati
{
new VmWareUsbSpeed( 0, Usb.NONE ).apply();
}
+
+ @Override
+ public String getSuspendedFile()
+ {
+ return config.get( "checkpoint.vmState" );
+ }
}