[libvirt] [PATCHv3 2/4] API: Add api to set and get domain metadata
Eric Blake
eblake at redhat.com
Wed Feb 1 16:34:11 UTC 2012
On 02/01/2012 06:03 AM, Peter Krempa wrote:
> This patch adds API to modify domain metadata for running and stopped
> domains. The api supports changing description, title as well as the
> newly added <metadata> element. The API has support for storing data in
> the metadata element using xml namespaces.
>
> * include/libvirt/libvirt.h.in
> * src/libvirt_public.syms
> - add function headers
> - add enum to select metadata to operate on
> - export functions
> * src/libvirt.c
> - add public api implementation
> * src/driver.h
> - add driver support
> * src/remote/remote_driver.c
> * src/remote/remote_protocol.x
> - wire up the remote protocol
> * include/libvirt/virterror.h
> * src/util/virterror.c
> - add a new error message note that metadata for domain are
> missing
> ---
> include/libvirt/libvirt.h.in | 24 ++++++
> include/libvirt/virterror.h | 1 +
> src/driver.h | 16 ++++
> src/libvirt.c | 178 ++++++++++++++++++++++++++++++++++++++++++
> src/libvirt_public.syms | 2 +
> src/remote/remote_driver.c | 2 +
> src/remote/remote_protocol.x | 24 ++++++-
> src/remote_protocol-structs | 19 +++++
> src/util/virterror.c | 6 ++
> 9 files changed, 271 insertions(+), 1 deletions(-)
ACK with one nit:
> +++ b/src/util/virterror.c
> @@ -1226,6 +1226,12 @@ virErrorMsg(virErrorNumber error, const char *info)
> else
> errmsg = _("operation aborted: %s");
> break;
> + case VIR_ERR_NO_DOMAIN_METADATA:
> + if (info == NULL)
> + errmsg = _("metadata not found");
> + else
> + errmsg = _("metadata not found");
The else branch should be:
"metadata not found: %s"
--
Eric Blake eblake at redhat.com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20120201/21bed855/attachment-0001.sig>
More information about the libvir-list
mailing list