Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 133734 Details for
Bug 272528
[WorkingSets] AIOOBE when trying to remove breakpoint by doubleclick on nearby line
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
snippet to reproduce the bug
patch_snippet1_272528.txt (text/plain), 3.04 KB, created by
Hitesh
on 2009-04-29 05:50:23 EDT
(
hide
)
Description:
snippet to reproduce the bug
Filename:
MIME Type:
Creator:
Hitesh
Created:
2009-04-29 05:50:23 EDT
Size:
3.04 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.ui.tests >Index: Eclipse UI Tests/org/eclipse/ui/tests/api/IWorkingSetManagerTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/api/IWorkingSetManagerTest.java,v >retrieving revision 1.21 >diff -u -r1.21 IWorkingSetManagerTest.java >--- Eclipse UI Tests/org/eclipse/ui/tests/api/IWorkingSetManagerTest.java 23 Apr 2009 17:53:05 -0000 1.21 >+++ Eclipse UI Tests/org/eclipse/ui/tests/api/IWorkingSetManagerTest.java 29 Apr 2009 09:40:42 -0000 >@@ -13,9 +13,14 @@ > import org.eclipse.core.resources.IWorkspace; > import org.eclipse.core.resources.ResourcesPlugin; > import org.eclipse.core.runtime.IAdaptable; >+import org.eclipse.core.runtime.IProgressMonitor; >+import org.eclipse.core.runtime.IStatus; >+import org.eclipse.core.runtime.Status; >+import org.eclipse.core.runtime.jobs.Job; > import org.eclipse.jface.resource.ImageDescriptor; > import org.eclipse.jface.util.IPropertyChangeListener; > import org.eclipse.jface.util.PropertyChangeEvent; >+import org.eclipse.swt.widgets.Display; > import org.eclipse.ui.IMemento; > import org.eclipse.ui.IWorkbenchWindow; > import org.eclipse.ui.IWorkingSet; >@@ -385,6 +390,71 @@ > } > } > >+ /* >+ * Not a definite test ,but a snippet to reproduce the bug 272528 >+ */ >+ public void testConcurrentGetWorkingSets() throws Throwable { >+ IWorkingSet[] testSets = new IWorkingSet[50]; >+ for (int i = 0; i < testSets.length; i++) { >+ testSets[i] = fWorkingSetManager.createWorkingSet(i >+ + WORKING_SET_NAME_1 + i, new IAdaptable[0]); >+ fWorkingSetManager.addWorkingSet(testSets[i]); >+ } >+ final String familyName = "testWorkingSetManagerThreadSafety"; >+ class WSetGetter extends Job { >+ boolean done = false; >+ >+ WSetGetter() { >+ super("WSetGetter"); >+ setSystem(true); >+ } >+ >+ protected IStatus run(IProgressMonitor monitor) { >+ try { >+ for (int i = 0; i < 1000; i++) { >+ fWorkingSetManager.getWorkingSets(); >+ if (i % 100 == 0) { >+ Thread.yield(); >+ } >+ } >+ } finally { >+ done = true; >+ } >+ return Status.OK_STATUS; >+ } >+ >+ public boolean belongsTo(Object family) { >+ return familyName == family; >+ } >+ } >+ WSetGetter[] getters = new WSetGetter[10]; >+ for (int i = 0; i < getters.length; i++) { >+ getters[i] = new WSetGetter(); >+ } >+ try { >+ for (int i = 0; i < getters.length; i++) { >+ getters[i].schedule(); >+ fWorkingSetManager.getWorkingSets(); >+ } >+ >+ boolean sleep = true; >+ while (sleep) { >+ Thread.sleep(200); >+ Display.getDefault().readAndDispatch(); >+ fWorkingSetManager.getWorkingSets(); >+ sleep = false; >+ for (int i = 0; i < getters.length && !sleep; i++) { >+ if (!getters[i].done) { >+ sleep = true; >+ } >+ } >+ } >+ } finally { >+ for (int i = 0; i < testSets.length; i++) { >+ fWorkingSetManager.removeWorkingSet(testSets[i]); >+ } >+ } >+ } > /** > * @param setIds > * @param i
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 272528
: 133734 |
134784
|
134785