jsip
  1. jsip
  2. JSIP-422

Concurrency issue in SipClientTransaction

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      I've found a concurrency issue in the SipClientTransaction.java with the used HashSet for the "responsesReceived" member.
      Access to this set occurs from different UdpMessageChannel threads although the java.util.HashSet is not thread safe.
      This causes endless loops in the IBM JVM which has a unfixed bug in the HashSet implementation, see http://www-01.ibm.com/support/docview.wss?uid=swg21427374 for further infos.

      My suggestion is to use the CopyOnWriteArraySet instead. Please use the attached patch file.

      Maybe there are other concurrent usages of HashSet and HashMap which should also be converted to CopyOnWriteArraySet/ConcurrentHashMap to avoid problems although I've not found bugs so far.

        Activity

        Hide
        deruelle_jean added a comment -

        Fixed in r2024

        Show
        deruelle_jean added a comment - Fixed in r2024

          People

          • Assignee:
            Unassigned
            Reporter:
            fre
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: