Jackrabbit Content Repository
  1. Jackrabbit Content Repository
  2. JCR-905

Clustering: race condition may cause duplicate entries in search index

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.2.1, 1.2.2, 1.2.3, 1.3, 1.3.1
    • Fix Version/s: 1.3.3
    • Component/s: clustering
    • Labels:
      None

      Description

      There seems to be a race condition that may cause duplicate search index entries. It is reproducible as follows (Jackrabbit 1.3):
      1) Start clusternode 1 that just adds a single node of node type clustering:test.
      2) Shutdown clusternode 1.
      3) Start clusternode 2 with an empty search index.
      4) Execute the query //element(*, clustering:test).
      4) Print the result of the query (UUIDs of nodes in the result set).

      When I just run clusternode 2, then there is one node in the resultset, as expected. However, when I debug clusternode 2 and have a breakpoint (i.e., a pause of a few seconds at line 306 of RepositoryImpl.java - just before the clusternode is started), then the resultset contains two results, both with the same UUID.

      1. SearchManager.patch
        0.8 kB
        Marcel Reutegger
      2. log2.txt
        2 kB
        Martijn Hendriks
      3. log1.txt
        1 kB
        Martijn Hendriks
      4. JCR-905.patch
        0.8 kB
        Martijn Hendriks

        Issue Links

          Activity

          Martijn Hendriks created issue -
          Martijn Hendriks made changes -
          Field Original Value New Value
          Attachment log1.txt [ 12356976 ]
          Attachment log2.txt [ 12356977 ]
          Martijn Hendriks made changes -
          Attachment JCR-905.patch [ 12357997 ]
          Dominique Pfister made changes -
          Component/s core [ 12310114 ]
          Component/s clustering [ 12311801 ]
          Martijn Hendriks made changes -
          Link This issue blocks JCR-1087 [ JCR-1087 ]
          Marcel Reutegger made changes -
          Attachment SearchManager.patch [ 12365544 ]
          Marcel Reutegger made changes -
          Fix Version/s 1.4 [ 12312447 ]
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Jukka Zitting made changes -
          Affects Version/s 1.2.2 [ 12312228 ]
          Fix Version/s 1.3.2 [ 12312770 ]
          Affects Version/s 1.2.1 [ 12312100 ]
          Affects Version/s 1.3.1 [ 12312512 ]
          Affects Version/s 1.2.3 [ 12312329 ]
          Fix Version/s 1.4 [ 12312447 ]
          Jukka Zitting made changes -
          Status Resolved [ 5 ] Closed [ 6 ]
          Jukka Zitting made changes -
          Workflow jira [ 12403540 ] no-reopen-closed, patch-avail [ 12468896 ]
          Gavin made changes -
          Link This issue blocks JCR-1087 [ JCR-1087 ]
          Gavin made changes -
          Link This issue is depended upon by JCR-1087 [ JCR-1087 ]

            People

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

              Dates

              • Created:
                Updated:
                Resolved:

                Development