[Openstack] eventlet and OpenStack external libraries

Yun Mao yunmao at gmail.com
Tue Mar 13 17:55:13 UTC 2012


Hi JE,

There are two places in the current master branch that use tpool:
NWFilterFirewall and XenAPISession. Are they safe?

I think if it's a pure C-based API call, then monkey patch should not
mess with it and it shouldn't try to reschedule among co-routines,
right?

After examining, the code, I see all libvirt-based calls are blocking,
and XenAPIs are non-blocking. This probably makes a huge difference in
a non-trivial deployment. However, libvirt-based KVM is probably the
most widely adopted choice right now, which is very strange..

Thanks,

Yun

On Mon, Mar 12, 2012 at 4:18 PM, Johannes Erdfelt <johannes at erdfelt.com> wrote:
> On Mon, Mar 12, 2012, Yun Mao <yunmao at gmail.com> wrote:
>> My understanding is that if the answer to question3 is yes, then the
>> blocking call should be executed in tpool, although it's more likely
>> to have bugs in that case.
>
> Please be very careful with tpool. If the code being executed in the
> tpool thread ends up using a lock that can contend with code executing
> the main thread, you can end up with the tpool thread hanging.
>
> In particular, using logging can trigger this hang. You would need to
> audit the library to ensure it's safe to be used.
>
> This is one of the reasons I'd prefer to see Openstack move away from
> eventlet. It has a handful of problems that requires a high level of
> diligence to avoid properly.
>
> JE
>
>
> _______________________________________________
> Mailing list: https://launchpad.net/~openstack
> Post to     : openstack at lists.launchpad.net
> Unsubscribe : https://launchpad.net/~openstack
> More help   : https://help.launchpad.net/ListHelp




More information about the Openstack mailing list