Uploaded image for project: 'Cassandra'
  1. Cassandra
  2. CASSANDRA-3681

Multiple threads can attempt hint handoff to the same target

Agile BoardAttach filesAttach ScreenshotBulk Copy AttachmentsBulk Move AttachmentsVotersWatch issueWatchersCreate sub-taskConvert to sub-taskMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Low
    • Resolution: Fixed
    • 1.0.7
    • None
    • Low

    Description

      HintedHandOffManager attempts to prevent multiple threads sending hints to the same target with the queuedDeliveries set, but the code is buggy. If two handoffs do occur concurrently, the second thread can use an arbitrarily large amount of memory skipping tombstones when it starts paging from the beginning of the hint row, looking for the first live hint. (This is not a problem with a single thread, since it always pages starting with the last-seen hint column name, effectively skipping the tombstones. Then it compacts when it's done.)

      Technically this bug is present in all older Cassandra releases, but it only causes problems in 1.0.x since the hint rows tend to be much larger (since there is one hint per write containing the entire mutation, instead of just one per row consisting of just the key).

      Attachments

        1. 3681.txt
          3 kB
          Jonathan Ellis
        2. 3681v2.txt
          4 kB
          Brandon Williams
        3. 3681-v3.txt
          6 kB
          Jonathan Ellis

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            jbellis Jonathan Ellis Assign to me
            jbellis Jonathan Ellis
            Jonathan Ellis
            Brandon Williams
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment