Re: [libvirt] RFE: virConnectListAllDomains()

2012-05-21 Thread Daniel P. Berrange
On Sun, May 20, 2012 at 05:20:36PM +0200, Peter Krempa wrote: On 05/19/2012 01:52 AM, Eric Blake wrote: Use of virConnectListDomains() and virConnectListDefinedDomains() is: 1. inherently racy. A domain can change between active and inactive between two back-to-back calls, and thus be

Re: [libvirt] RFE: virConnectListAllDomains()

2012-05-21 Thread Daniel P. Berrange
On Fri, May 18, 2012 at 05:52:36PM -0600, Eric Blake wrote: Use of virConnectListDomains() and virConnectListDefinedDomains() is: 1. inherently racy. A domain can change between active and inactive between two back-to-back calls, and thus be entirely skipped or enumerated twice when

Re: [libvirt] RFE: virConnectListAllDomains()

2012-05-21 Thread Eric Blake
On 05/20/2012 09:20 AM, Peter Krempa wrote: On 05/19/2012 01:52 AM, Eric Blake wrote: Use of virConnectListDomains() and virConnectListDefinedDomains() is: + +int virConnectListAllDomains(virConnectPtr conn, + virDomainPtr

Re: [libvirt] RFE: virConnectListAllDomains()

2012-05-20 Thread Peter Krempa
On 05/19/2012 01:52 AM, Eric Blake wrote: Use of virConnectListDomains() and virConnectListDefinedDomains() is: 1. inherently racy. A domain can change between active and inactive between two back-to-back calls, and thus be entirely skipped or enumerated twice when concatenating lists. 2.

Re: [libvirt] RFE: virConnectListAllDomains()

2012-05-19 Thread dennis jenkins
On Fri, May 18, 2012 at 6:52 PM, Eric Blake ebl...@redhat.com wrote: Use of virConnectListDomains() and virConnectListDefinedDomains() is: 1. inherently racy. A domain can change between active and inactive between two back-to-back calls, and thus be entirely skipped or enumerated twice

[libvirt] RFE: virConnectListAllDomains()

2012-05-18 Thread Eric Blake
Use of virConnectListDomains() and virConnectListDefinedDomains() is: 1. inherently racy. A domain can change between active and inactive between two back-to-back calls, and thus be entirely skipped or enumerated twice when concatenating lists. 2. painful to use. ListDomains gives ids,