glazedlists
  1. glazedlists
  2. GLAZEDLISTS-487

IndexOutOfBoundsException in ThreadProxyEventList

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Incomplete
    • Affects Version/s: current
    • Fix Version/s: milestone 1
    • Component/s: core
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      487

      Description

      I've stack of events lists, which is updated from separate worker threads. It
      seems that in some case, IndexOutOfBoundsException is triggered in proxy list
      updater logic.

      Without fully understanding the cause, it sounds for me that access into source
      list is done without readlock, thus running into race condition with worker
      thread

      Q: Is usage of ThreadSafeList required when using ThreadProxyEventList and
      worker threads updating underlying source lists?

      -------------
      M!Error occurred in EventDispatching
      java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
      at java.util.ArrayList.RangeCheck(ArrayList.java:547)
      at java.util.ArrayList.get(ArrayList.java:322)
      at ca.odell.glazedlists.BasicEventList.get(BasicEventList.java:225)
      at ca.odell.glazedlists.CollectionList$EventChildElement.get
      (CollectionList.java:444)
      at ca.odell.glazedlists.CollectionList.get(CollectionList.java:128)
      at ca.odell.glazedlists.TransformedList.get(TransformedList.java:106)
      at ca.odell.glazedlists.TransformedList.get(TransformedList.java:106)
      at ca.odell.glazedlists.TransformedList.get(TransformedList.java:106)
      at ca.odell.glazedlists.impl.gui.ThreadProxyEventList.applyChangeToCache
      (ThreadProxyEventList.java:189)
      at ca.odell.glazedlists.impl.gui.ThreadProxyEventList.access
      $600(ThreadProxyEventList.java:68)
      at
      ca.odell.glazedlists.impl.gui.ThreadProxyEventList$UpdateRunner.listChanged
      (ThreadProxyEventList.java:242)
      at ca.odell.glazedlists.event.ListEventAssembler$ListEventFormat.fire
      (ListEventAssembler.java:412)
      at ca.odell.glazedlists.event.ListEventAssembler$ListEventFormat.fire
      (ListEventAssembler.java:409)
      at
      ca.odell.glazedlists.event.SequenceDependenciesEventPublisher
      $SubjectAndListener.firePendingEvent
      (SequenceDependenciesEventPublisher.java:445)
      at
      ca.odell.glazedlists.event.SequenceDependenciesEventPublisher.fireEvent
      (SequenceDependenciesEventPublisher.java:344)
      at ca.odell.glazedlists.event.ListEventAssembler.commitEvent
      (ListEventAssembler.java:316)
      at ca.odell.glazedlists.impl.gui.ThreadProxyEventList$UpdateRunner.run
      (ThreadProxyEventList.java:230)
      at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
      at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
      at java.awt.EventDispatchThread.pumpOneEventForFilters
      (EventDispatchThread.java:269)
      at java.awt.EventDispatchThread.pumpEventsForFilter
      (EventDispatchThread.java:184)
      at java.awt.EventDispatchThread.pumpEventsForHierarchy
      (EventDispatchThread.java:174)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
      at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

        Activity

        Hide
        kikonen added a comment -

        I think so this issue what I created is invalid

        Show
        kikonen added a comment - I think so this issue what I created is invalid

          People

          • Assignee:
            jessewilson
            Reporter:
            kikonen
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: