Uploaded image for project: 'Jackrabbit Oak'
  1. Jackrabbit Oak
  2. OAK-7950

oak-run check crashes with UncheckedExecutionException (caused by SNFE)

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.8.9
    • Fix Version/s: 1.8.10
    • Component/s: run, segment-tar
    • Labels:
      None

      Description

      There was a crash for oak-run check which ended with a UncheckedExecutionException (caused under the hood by an SNFE):

      Checking checkpoint 8c9bfd14-3e96-49c3-805f-c7cc8e85fc26
      com.google.common.util.concurrent.UncheckedExecutionException: org.apache.jackrabbit.oak.segment.SegmentNotFoundException: Segment c909911f-0456-4b1d-a44f-7e72f28e6214 not found
      at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2199)
      at com.google.common.cache.LocalCache.get(LocalCache.java:3932)
      at com.google.common.cache.LocalCache$LocalManualCache.get(LocalCache.java:4721)
      at org.apache.jackrabbit.oak.segment.SegmentCache.getSegment(SegmentCache.java:113)
      at org.apache.jackrabbit.oak.segment.file.ReadOnlyFileStore.readSegment(ReadOnlyFileStore.java:114)
      at org.apache.jackrabbit.oak.segment.SegmentId.getSegment(SegmentId.java:154)
      at org.apache.jackrabbit.oak.segment.Record.getSegment(Record.java:70)
      at org.apache.jackrabbit.oak.segment.MapRecord.getEntry(MapRecord.java:161)
      at org.apache.jackrabbit.oak.segment.MapRecord.getEntry(MapRecord.java:173)
      at org.apache.jackrabbit.oak.segment.SegmentNodeState.getChildNode(SegmentNodeState.java:423)
      at org.apache.jackrabbit.oak.segment.SegmentNodeStore.retrieve(SegmentNodeStore.java:289)
      at org.apache.jackrabbit.oak.segment.file.tooling.ConsistencyChecker.checkConsistency(ConsistencyChecker.java:216)
      at org.apache.jackrabbit.oak.segment.tool.Check.run(Check.java:243)
      at org.apache.jackrabbit.oak.run.CheckCommand.execute(CheckCommand.java:95)
      at org.apache.jackrabbit.oak.run.Main.main(Main.java:49)
      Caused by: org.apache.jackrabbit.oak.segment.SegmentNotFoundException: Segment c909911f-0456-4b1d-a44f-7e72f28e6214 not found
      at org.apache.jackrabbit.oak.segment.file.AbstractFileStore.readSegmentUncached(AbstractFileStore.java:276)
      at org.apache.jackrabbit.oak.segment.file.ReadOnlyFileStore$1.call(ReadOnlyFileStore.java:117)
      at org.apache.jackrabbit.oak.segment.file.ReadOnlyFileStore$1.call(ReadOnlyFileStore.java:114)
      at org.apache.jackrabbit.oak.segment.SegmentCache.lambda$getSegment$0(SegmentCache.java:116)
      at com.google.common.cache.LocalCache$LocalManualCache$1.load(LocalCache.java:4724)
      at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3522)
      at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2315)
      at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2278)
      at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2193)
      ... 14 more
      

      Since this comes from the cache and is wrapped in a UncheckedExecutionException, the catch block in ConsistencyChecker introduced in OAK-7837, fails to deal with it, causing erroneous termination of the check.

        Attachments

          Activity

            People

            • Assignee:
              dulceanu Andrei Dulceanu
              Reporter:
              dulceanu Andrei Dulceanu
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: