Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 356324

Summary: Table: editing a bunch of values in sorted table causes java.util.ConcurrentModificationException
Product: z_Archived Reporter: Stephan Merkli <stephan.merkli>
Component: ScoutAssignee: Project Inbox <scout.core-inbox>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: Andreas.Hoegger
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Attachments:
Description Flags
Example form showing the described behaviour none

Description Stephan Merkli CLA 2011-08-31 09:18:57 EDT
Build Identifier: M20110210-1200

Example form is attached.
When having a sorted table with for example 1000 entries, and all values are modified, say a "+" is added to the value in a string column, the following exception occurs (the action is executed nevertheless).

Exception in thread "AWT-EventQueue-0" java.util.ConcurrentModificationException
	at java.util.TreeMap$PrivateEntryIterator.nextEntry(TreeMap.java:1100)
	at java.util.TreeMap$KeyIterator.next(TreeMap.java:1154)
	at java.util.AbstractCollection.toArray(AbstractCollection.java:171)
	at org.eclipse.scout.rt.client.ui.basic.table.AbstractTable.getSelectedRows(AbstractTable.java:1481)
	at org.eclipse.scout.rt.ui.swing.basic.table.SwingScoutTable.setSelectionFromScout(SwingScoutTable.java:426)
	at org.eclipse.scout.rt.ui.swing.basic.table.SwingScoutTable.handleScoutTableEventInSwing(SwingScoutTable.java:674)
	at org.eclipse.scout.rt.ui.swing.basic.table.SwingScoutTable$P_ScoutTableListener$2.run(SwingScoutTable.java:1488)
	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)

Reproducible: Always

Steps to Reproduce:
1. Use the provided code
2. Context menu 'edit with sort disabled' works
3. Context menu 'edit with sort enabled' causes exception (only visible in console)
Comment 1 Stephan Merkli CLA 2011-08-31 09:19:24 EDT
Created attachment 202516 [details]
Example form showing the described behaviour
Comment 2 Andreas Hoegger CLA 2015-04-14 10:12:17 EDT
fixed
Comment 3 Matthias Zimmermann CLA 2015-07-06 08:10:39 EDT
Shipped with Luna SR2
Comment 4 Matthias Zimmermann CLA 2015-07-06 09:09:52 EDT
Shipped with Luna SR2 (or an earlier Luna release)