Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6345077

Javadoc for ConcurrentLinkedQueue is deficient

    XMLWordPrintable

    Details

      Description

      A DESCRIPTION OF THE REQUEST :
      The current javadoc for ConcurrentLinkedQueue says that it is a straight implementation of the Michael-Scott algorithm and gives a link to where the algorithm can be found. However this isn't quite correct. The implementation does not contain code to solve the ABA problem.

      Given that a reference to the original A is held by the method, the garbage collector is essentially guaranteeing that the ABA problem can't happen. However it is not intuitively obvious that this is the case and it ought to be made explicit in the documentation that there is no correct for the ABA problem in this java implementation.

      JUSTIFICATION :
      I got confused and spent a day trying to figure out what was going on!

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      Docs ought to be clear about implementation.
      ACTUAL -
      Docs are somewhat vague.

        Attachments

          Activity

            People

            Assignee:
            martin Martin Buchholz
            Reporter:
            gmanwanisunw Girish Manwani (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: