Qpid
  1. Qpid
  2. QPID-4764

Locking may lead to deadlock for concurrent receiver

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.22
    • Fix Version/s: 0.23
    • Component/s: C++ Client
    • Labels:
      None

      Description

      The lock ordering leaves open the possibility of a deadlock if one thread is fetching on a receiver, another is accepting messages received by it and a third is closing the receiver.

      Thread 1 holds SessionImpl's lock and is blocked on IncomingMessage's lock. Thread 2 holds IncomingMessage's lock and is blocked on ReceiverImpl's lock. Thread 3 holds the ReceiverImpl's lock and is blocked on SessionImpl's lock.

      I have been unable to reproduce this myself, but an actual incidence has been reported: https://bugzilla.redhat.com/show_bug.cgi?id=703891

        Activity

        Gordon Sim created issue -
        Hide
        Gordon Sim added a comment -

        Fix available for review: https://reviews.apache.org/r/10704/

        Show
        Gordon Sim added a comment - Fix available for review: https://reviews.apache.org/r/10704/
        Show
        Gordon Sim added a comment - Fixed in http://svn.apache.org/viewvc?view=revision&revision=1475723
        Gordon Sim made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Hide
        Justin Ross added a comment -
        Show
        Justin Ross added a comment - Released in Qpid 0.24, http://qpid.apache.org/releases/qpid-0.24/index.html
        Justin Ross made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Resolved Resolved
        2d 23h 14m 1 Gordon Sim 25/Apr/13 13:29
        Resolved Resolved Closed Closed
        136d 1h 8m 1 Justin Ross 08/Sep/13 14:37

          People

          • Assignee:
            Gordon Sim
            Reporter:
            Gordon Sim
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development