Uploaded image for project: 'Confluence Server'
  1. Confluence Server
  2. CONFSERVER-34226

Detect loops when going through page tree structure

    Details

      Description

      Sometimes, the ancestors table gets out of synch and that can generate infinite loops when trying to generate the breadcrumbs or generating a page tree. This can lead to OutOfMemory and StackOverflow errors affecting the stability of Confluence.

      We should be able to detect these loops and point the user to rebuild the ancestors table (or even rebuild it automatically).

      Workaround #1 (if only ancestors table is corrupted)

      If you are facing this kind of problems try Rebuilding the Ancestor Table.

      Workaround #2 (if both content and ancestors table are corrupted)

      • Disable tree macro (if eill make instance unusable in few minutes if enabled and loop exist)
      • Find loop in db using
        SELECT *
        FROM content as parent
        LEFT JOIN content AS child
        ON child.parentid = parent.contentid
        WHERE parent.parentid = child.contentid
        

        query

      • Fix parent<->child relation
      • Rebuild the Ancestor Table
      • Enable tree macro

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                9 Vote for this issue
                Watchers:
                22 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Last commented:
                  1 year, 37 weeks ago