Uploaded image for project: 'Jackrabbit Content Repository'
  1. Jackrabbit Content Repository
  2. JCR-1271

NullPointerException when iterating over properties

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.3.4, 1.4
    • Component/s: jackrabbit-core
    • Labels:
      None

      Description

      Running ConcurrentReadWriteTest (NUM_NODES=5, NUM_THREADS=3, RUN_NUM_SECONDS=120) resulted in a NullPointerException:

      Exception in thread "Thread-11" java.lang.NullPointerException
      at org.apache.commons.collections.map.AbstractReferenceMap$ReferenceEntry.getValue(AbstractReferenceMap.java:596)
      at org.apache.commons.collections.map.AbstractReferenceMap.containsKey(AbstractReferenceMap.java:204)
      at org.apache.jackrabbit.core.state.ItemStateMap.contains(ItemStateMap.java:66)
      at org.apache.jackrabbit.core.state.ItemStateReferenceCache.isCached(ItemStateReferenceCache.java:91)
      at org.apache.jackrabbit.core.state.LocalItemStateManager.hasItemState(LocalItemStateManager.java:173)
      at org.apache.jackrabbit.core.state.XAItemStateManager.hasItemState(XAItemStateManager.java:252)
      at org.apache.jackrabbit.core.state.SessionItemStateManager.getItemState(SessionItemStateManager.java:174)
      at org.apache.jackrabbit.core.ItemManager.createItemInstance(ItemManager.java:495)
      at org.apache.jackrabbit.core.ItemManager.getItem(ItemManager.java:326)
      at org.apache.jackrabbit.core.LazyItemIterator.prefetchNext(LazyItemIterator.java:90)
      at org.apache.jackrabbit.core.LazyItemIterator.next(LazyItemIterator.java:203)
      at org.apache.jackrabbit.core.LazyItemIterator.nextProperty(LazyItemIterator.java:118)
      at org.apache.jackrabbit.core.ConcurrentReadWriteTest$1$1.execute(ConcurrentReadWriteTest.java:64)
      at org.apache.jackrabbit.core.AbstractConcurrencyTest$Executor.run(AbstractConcurrencyTest.java:110)
      at java.lang.Thread.run(Thread.java:619)

      The cache is not synchronized and is accessed at the same time by the current thread and another thread that notified ItemStates about changes.

        Attachments

        1. JCR-1271.patch
          7 kB
          Marcel Reutegger
        2. JCR-1271.patch
          7 kB
          Marcel Reutegger
        3. JCR-1271.patch
          6 kB
          Marcel Reutegger
        4. JCR-1271.jz.patch
          9 kB
          Jukka Zitting

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              mreutegg Marcel Reutegger
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: