mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-09 23:15:51 -06:00
Introduce new VIR_DOMAIN_EVENT_SUSPENDED_API_ERROR event
This is supposed to be thrown every time we need to pause domain because of API execution (e.g. qemuDomainSaveInternal) but fails to restore it back after. In this case, domain remains paused, however, none of existing reasons can fit this scenario.
This commit is contained in:
parent
5f63a5cb42
commit
adb29a8869
@ -149,6 +149,9 @@ static const char *eventDetailToString(int event, int detail) {
|
||||
case VIR_DOMAIN_EVENT_SUSPENDED_FROM_SNAPSHOT:
|
||||
ret = "Snapshot";
|
||||
break;
|
||||
case VIR_DOMAIN_EVENT_SUSPENDED_API_ERROR:
|
||||
ret = "API error";
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case VIR_DOMAIN_EVENT_RESUMED:
|
||||
|
@ -445,7 +445,7 @@ def detailToString(event, detail):
|
||||
( "Added", "Updated" ),
|
||||
( "Removed", ),
|
||||
( "Booted", "Migrated", "Restored", "Snapshot", "Wakeup" ),
|
||||
( "Paused", "Migrated", "IOError", "Watchdog", "Restored", "Snapshot" ),
|
||||
( "Paused", "Migrated", "IOError", "Watchdog", "Restored", "Snapshot", "API error" ),
|
||||
( "Unpaused", "Migrated", "Snapshot" ),
|
||||
( "Shutdown", "Destroyed", "Crashed", "Migrated", "Saved", "Failed", "Snapshot"),
|
||||
( "Finished", ),
|
||||
|
@ -3159,6 +3159,7 @@ typedef enum {
|
||||
VIR_DOMAIN_EVENT_SUSPENDED_WATCHDOG = 3, /* Suspended due to a watchdog firing */
|
||||
VIR_DOMAIN_EVENT_SUSPENDED_RESTORED = 4, /* Restored from paused state file */
|
||||
VIR_DOMAIN_EVENT_SUSPENDED_FROM_SNAPSHOT = 5, /* Restored from paused snapshot */
|
||||
VIR_DOMAIN_EVENT_SUSPENDED_API_ERROR = 6, /* suspended after failure during libvirt API call */
|
||||
|
||||
#ifdef VIR_ENUM_SENTINELS
|
||||
VIR_DOMAIN_EVENT_SUSPENDED_LAST
|
||||
|
Loading…
Reference in New Issue
Block a user