directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pierre-Arnaud Marcelot (JIRA)" <j...@apache.org>
Subject [jira] Closed: (DIRSTUDIO-288) "SWTError: No more handles" error when repeatedly adding a new entry
Date Fri, 13 Jun 2008 13:00:45 GMT

     [ https://issues.apache.org/jira/browse/DIRSTUDIO-288?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Pierre-Arnaud Marcelot closed DIRSTUDIO-288.
--------------------------------------------


Version 1.1.0 has been released.
Closing this issue.

> "SWTError: No more handles" error when repeatedly adding a new entry
> --------------------------------------------------------------------
>
>                 Key: DIRSTUDIO-288
>                 URL: https://issues.apache.org/jira/browse/DIRSTUDIO-288
>             Project: Directory Studio
>          Issue Type: Bug
>          Components: studio-ldapbrowser
>    Affects Versions: 1.1.0
>         Environment: Windows XP SP2 all current updates applied
> Eclipse 3.3
> JDK1.5.0_11 with a 512m heap size
> Directory Studio 1.1.0
> Open DS 1.0.0
>            Reporter: John Buslawski
>            Assignee: Stefan Seelmann
>            Priority: Critical
>             Fix For: 1.1.0
>
>
> When adding a new entry in Directory Studio, Eclipse sometimes will crash with a "SWTError:
No more handles" error combined with either an OutOfMemoryError, an ArrayIndexOutOfBoundsException,
or NegativeArraySizeException.  The following steps were used to reproduce the problem:
> Connect via LDAP Browser to an LDAP server.
> Expand out the tree and pick an group object. In our implementation it would look like
> dc=initiatesystems,dc=com > ou=Groups > ou=System. Right-click on "cn=All Interactions"
and select New Entry. ("All Interactions" is a group object.)
> In the New Entry dialog select "Create from scratch", click Next.
> On the page, move the object classes from the right side to the left side one at a time
starting with "account" (the first one).
> Once you have moved about 9 or 10 object classes to the left side, Eclipse will just
shutdown with no warning.
> The following was in the Eclipse .log file:
> !ENTRY org.eclipse.ui 4 0 2008-03-03 16:22:22.806
> !MESSAGE Unhandled event loop exception
> !STACK 0
> org.eclipse.swt.SWTError: No more handles
> 	at org.eclipse.swt.SWT.error(SWT.java:3589)
> 	at org.eclipse.swt.SWT.error(SWT.java:3481)
> 	at org.eclipse.swt.SWT.error(SWT.java:3452)
> 	at org.eclipse.swt.graphics.Image.init(Image.java:1811)
> 	at org.eclipse.swt.graphics.Image.init(Image.java:1936)
> 	at org.eclipse.swt.graphics.Image.<init>(Image.java:490)
> 	at org.eclipse.jface.resource.ImageDescriptor.createImage(ImageDescriptor.java:289)
> 	at org.eclipse.jface.resource.ImageDescriptor.createImage(ImageDescriptor.java:227)
> 	at org.eclipse.jface.resource.ImageDescriptor.createImage(ImageDescriptor.java:205)
> 	at org.apache.directory.studio.ldapbrowser.ui.wizards.NewEntryObjectclassWizardPage$1.getImage(Unknown
Source)
> 	at org.eclipse.jface.viewers.WrappedViewerLabelProvider.getImage(WrappedViewerLabelProvider.java:117)
> 	at org.eclipse.jface.viewers.WrappedViewerLabelProvider.update(WrappedViewerLabelProvider.java:165)
> 	at org.eclipse.jface.viewers.ViewerColumn.refresh(ViewerColumn.java:135)
> 	at org.eclipse.jface.viewers.AbstractTableViewer.doUpdateItem(AbstractTableViewer.java:386)
> 	at org.eclipse.jface.viewers.StructuredViewer$UpdateItemSafeRunnable.run(StructuredViewer.java:466)
> 	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
> 	at org.eclipse.core.runtime.Platform.run(Platform.java:857)
> 	at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:46)
> 	at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:193)
> 	at org.eclipse.jface.viewers.StructuredViewer.updateItem(StructuredViewer.java:2026)
> 	at org.eclipse.jface.viewers.AbstractTableViewer.internalRefreshAll(AbstractTableViewer.java:692)
> 	at org.eclipse.jface.viewers.AbstractTableViewer.internalRefresh(AbstractTableViewer.java:630)
> 	at org.eclipse.jface.viewers.AbstractTableViewer.internalRefresh(AbstractTableViewer.java:617)
> 	at org.eclipse.jface.viewers.StructuredViewer$7.run(StructuredViewer.java:1433)
> 	at org.eclipse.jface.viewers.StructuredViewer.preservingSelection(StructuredViewer.java:1368)
> 	at org.eclipse.jface.viewers.StructuredViewer.preservingSelection(StructuredViewer.java:1330)
> 	at org.eclipse.jface.viewers.StructuredViewer.refresh(StructuredViewer.java:1431)
> 	at org.eclipse.jface.viewers.ColumnViewer.refresh(ColumnViewer.java:503)
> 	at org.eclipse.jface.viewers.StructuredViewer.refresh(StructuredViewer.java:1390)
> 	at org.apache.directory.studio.ldapbrowser.ui.wizards.NewEntryObjectclassWizardPage.add(Unknown
Source)
> 	at org.apache.directory.studio.ldapbrowser.ui.wizards.NewEntryObjectclassWizardPage.access$200(Unknown
Source)
> 	at org.apache.directory.studio.ldapbrowser.ui.wizards.NewEntryObjectclassWizardPage$7.widgetSelected(Unknown
Source)
> 	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:227)
> 	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
> 	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3682)
> 	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3293)
> 	at org.eclipse.jface.window.Window.runEventLoop(Window.java:820)
> 	at org.eclipse.jface.window.Window.open(Window.java:796)
> 	at org.apache.directory.studio.ldapbrowser.ui.actions.NewEntryAction.run(Unknown Source)
> 	at org.apache.directory.studio.ldapbrowser.common.actions.proxy.BrowserActionProxy.run(Unknown
Source)
> 	at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
> 	at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:545)
> 	at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:490)
> 	at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:402)
> 	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
> 	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3682)
> 	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3293)
> 	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2389)
> 	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353)
> 	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2219)
> 	at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
> 	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289)
> 	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461)
> 	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
> 	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:106)
> 	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:153)
> 	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106)
> 	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76)
> 	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363)
> 	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> 	at java.lang.reflect.Method.invoke(Unknown Source)
> 	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:504)
> 	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:443)
> 	at org.eclipse.equinox.launcher.Main.run(Main.java:1169)
> 	at org.eclipse.equinox.launcher.Main.main(Main.java:1144)
> !ENTRY org.eclipse.ui 4 0 2008-03-03 16:23:21.728
> !MESSAGE Unhandled event loop exception
> !STACK 0
> org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.OutOfMemoryError:
Java heap space)
> 	at org.eclipse.swt.SWT.error(SWT.java:3563)
> 	at org.eclipse.swt.SWT.error(SWT.java:3481)
> 	at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:126)
> 	at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3659)
> 	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3296)
> 	at org.eclipse.jface.window.Window.runEventLoop(Window.java:820)
> 	at org.eclipse.jface.window.Window.open(Window.java:796)
> 	at org.apache.directory.studio.ldapbrowser.ui.actions.NewEntryAction.run(Unknown Source)
> 	at org.apache.directory.studio.ldapbrowser.common.actions.proxy.BrowserActionProxy.run(Unknown
Source)
> 	at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
> 	at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:545)
> 	at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:490)
> 	at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:402)
> 	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
> 	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
> 	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3682)
> 	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3293)
> 	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2389)
> 	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353)
> 	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2219)
> 	at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
> 	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289)
> 	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461)
> 	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
> 	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:106)
> 	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:153)
> 	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106)
> 	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76)
> 	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363)
> 	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> 	at java.lang.reflect.Method.invoke(Unknown Source)
> 	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:504)
> 	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:443)
> 	at org.eclipse.equinox.launcher.Main.run(Main.java:1169)
> 	at org.eclipse.equinox.launcher.Main.main(Main.java:1144)
> Caused by: java.lang.OutOfMemoryError: Java heap space
> We think the error comes from using createImage() rather than getImage() in the getImage()
method in the LabelProvider inner class of NewEntryObjectclassWizardPage. It appears as though
the images keep getting recreated with freeing them. For example, the following line:
>  BrowserUIPlugin.getDefault().getImageDescriptor( BrowserUIConstants.IMG_OCD_ABSTRACT
).createImage(); 
> should be replaced with:
>   
>  BrowserUIPlugin.getDefault().getImage( BrowserUIConstants.IMG_OCD_ABSTRACT );

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message