domain: Define explicit flags for saved image xml
Commit d2a929d4 (0.9.4) defined virDomainSaveImageGetXMLDesc()'s use of @flags as a subset of virDomainXMLFlags, documenting that 2 of the 3 flags defined at the time would never be valid. Later, commit 28f8dfdc (1.0.0) introduced a new flag, VIR_DOMAIN_XML_MIGRATABLE, but did not adjust the save image documentation to declare it as invalid. Later, commit a67e3872 (3.7.0) blindly copied and pasted the same text into virDomainManagedSaveGetXMLDesc. However, since the flag is not accepted as valid by any of the drivers (remote is just passthrough; and qemu is the only supporting driver for either API, with support for just VIR_DOMAIN_XML_SECURE), it is easier to just define an explicit set of supported flags directly related to the save image API rather than trying to borrow from live domain API, and risking confusion if even more domain flags are added later (in fact, I have an upcoming patch that plans to add a new flag to virDomainGetXMLDesc that makes no sense for saved images). We may someday decide that saved images need to support the _MIGRATABLE flag, as it is possible to load a saved image with a different version of libvirt than the one that created it, but that can be a separate patch if it is ever needed. Meanwhile, it DOES make sense to reuse the same flags for SaveImage and for ManagedSave (since ManagedSave is really just sugar for creating a normal SaveImage in a location controlled by libvirt instead of by the user). There is no API or ABI impact (since we purposefully used unsigned int rather than an enum type in public API, and since the new flag name carries the same value as the old reused name). Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NJohn Ferlan <jferlan@redhat.com>
Showing
-
mentioned in commit 4e16e7a3
-
mentioned in commit 99ac102b
-
mentioned in commit fa2016e7
-
mentioned in commit 470d6f55
-
mentioned in commit 980109c4
-
mentioned in commit 221397df
-
mentioned in commit b22baef3
-
mentioned in commit a8ae1784
-
mentioned in commit 70e83151
-
mentioned in commit a9e40f23
-
mentioned in commit dea40b42
-
mentioned in commit 97829dcb
-
mentioned in commit fb8c9f13
-
mentioned in commit ff5c64b9
-
mentioned in commit 8cf159fe
-
mentioned in commit 1f8129c5
-
mentioned in commit 7312304e
-
mentioned in commit 35725648
-
mentioned in commit 8832b8a4
-
mentioned in commit bafe00de
-
mentioned in commit a2765964
-
mentioned in commit 6a028b6e
-
mentioned in commit 3352c8af
-
mentioned in commit 56fadbbb
-
mentioned in commit 568c735d
-
mentioned in commit 6aa0c85b
想要评论请 注册 或 登录