Glance-api was able to hang in qpid notifier under heavy image creation load.
The ``thread`` and ``select`` modules used by the python-qpid for managing
the AMQP connection. When the eventlet was not able to switch between threads
because leaded to hang and/or pipe(2) leaking issues.
* Monkey patching the ``select`` and ``thread`` modules to be eventlet friendly
in order to avoid hanging issues.
* The reference to the connection object in the QpidStrategy
was replaceable by a concurrent thread, which could cause various issues.
Using just local variables for storing connection object in order to avoid
concurrent unsafe manipulation.
Reviewed: https:/ /review. openstack. org/50258 github. com/openstack/ glance/ commit/ 9a557c8f54e8ac0 db2f48bb95296ea 2a9ef9a7bb
Committed: http://
Submitter: Jenkins
Branch: stable/grizzly
commit 9a557c8f54e8ac0 db2f48bb95296ea 2a9ef9a7bb
Author: Attila Fazekas <email address hidden>
Date: Mon Sep 23 08:44:37 2013 +0200
Fixing glance-api hangs in the qpid notifier
Glance-api was able to hang in qpid notifier under heavy image creation load.
The ``thread`` and ``select`` modules used by the python-qpid for managing
the AMQP connection. When the eventlet was not able to switch between threads
because leaded to hang and/or pipe(2) leaking issues.
* Monkey patching the ``select`` and ``thread`` modules to be eventlet friendly
in order to avoid hanging issues.
* The reference to the connection object in the QpidStrategy
was replaceable by a concurrent thread, which could cause various issues.
Using just local variables for storing connection object in order to avoid
concurrent unsafe manipulation.
Fixing bug 1229042
Change-Id: I8fa8c4f36892b9 6d406216cb3c648 54a94ca9df7 f4cbd9703ee1909 0b6757508a)
(cherry picked from commit 2e7aa761b6c2b31