Re: [libvirt] PATCH 0/5: connection cloning support (WIP)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Dec 09, 2008 at 12:08:51PM +0000, Daniel P. Berrange wrote:
> This series is a work-in-progress set of patches implementing connection
> cloning. The idea is that if you want to use a connection form multiple
> threads, you could do
> 
>    virConnectPtr copy = virConnectClone(conn)
> 
> and use 'copy' from the other thread. This avoids the problem of having
> to make all the virError handling stuff thread-local whic is the blocker
> for allowing real mutlti-thread access to a single virConnectPtr object.
> 
> I believe this cloning support should be sufficient for the Java bindings
> need to use a thread for its event loop. The idea being that if you wanted
> to use an event loop in a background thread, you'd create a cloned object
> for use event loop triggered callbacks like domain events notifications.
> 
> I'd still like to do some experiments later making the single virConnectPtr
> fully thread safe, but that'll take a little more time. I'm hoping this
> cloning will address the Java needs right now...

  Interesting approach, one more possibility of handling things like
long-lasting operations, this could be generally useful even beyond
just the Java bindings.

Daniel

-- 
Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
daniel@xxxxxxxxxxxx  | Rpmfind RPM search engine http://rpmfind.net/
http://veillard.com/ | virtualization library  http://libvirt.org/

--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]