[libvirt] [PATCH v2] lib: Add note that bulk stats API queries may overrun RPC buffers

Richard W.M. Jones rjones at redhat.com
Wed May 24 12:47:10 UTC 2017

On Wed, May 24, 2017 at 12:49:58PM +0200, Michal Privoznik wrote:
> That's quite exact. I mean the word 'guessing'. We can't really provide
> reliable way of dealing with what you're suggesting (unless we cut the
> limit really small) nor we can guarantee atomicity. Therefore I think it
> would be a waste of time to work on this. Yes, it can be done, but the
> benefits are pretty small IMO.

Why is atomicity a problem?  Just structure the libvirtd
messages so that you have:

    - saves the stats into an internal buffer in libvirtd
      and returns a handle and a number of stat items
    - returns partial subset of previously collected stats,
      called multiple times to transfer the data back to libvirt
    - free the internal buffer


Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-builder quickly builds VMs from scratch

More information about the libvir-list mailing list