Comment 1 for bug 1805706

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to oslo.utils (master)

Reviewed: https://review.openstack.org/618482
Committed: https://git.openstack.org/cgit/openstack/oslo.utils/commit/?id=cc8b51e1e16f6bdc7d6c0e571e2002e70cde098d
Submitter: Zuul
Branch: master

commit cc8b51e1e16f6bdc7d6c0e571e2002e70cde098d
Author: Zane Bitter <email address hidden>
Date: Wed Nov 28 15:50:12 2018 -0500

    Fix race condition in eventletutils Event

    The threading-compatible eventlet Event class has a race condition on
    the wait method. If greenthread A is blocked on the wait, but another
    greenthread B calls clear() and then set(), B calls self._event.send(),
    but A is waiting on a different eventlet Event which is no longer used
    by the oslo.service Event...

    To resolve this, when clearing an Event trigger the underlying eventlet
    Event immediately, then have the wait() method resume waiting on the new
    eventlet Event.

    Change-Id: I81579e2977bb965a5398a2cb4e3e24f5671e856a
    Co-Authored-By: Victor Stinner <email address hidden>
    Co-Authored-By: HervĂ© Beraud <email address hidden>
    Closes-Bug: #1805706