Archi Forum

Archi Plug-ins => Other Plug-ins => Topic started by: Jose-Carlos on May 27, 2019, 14:07:11 PM

Title: Form plugin: org.eclipse.swt.SWTError: No more handles
Post by: Jose-Carlos on May 27, 2019, 14:07:11 PM
Hi,

I have open an issue about Form plugin (see https://github.com/archimatetool/archi/issues/476 (https://github.com/archimatetool/archi/issues/476)).

Archi execution fails with error: org.eclipse.swt.SWTError: No more handles.

Does anyone had the same behavior?

Any idea to solve this issue?

Thanks.
Title: Re: Form plugin: org.eclipse.swt.SWTError: No more handles
Post by: Phil Beauvoir on May 27, 2019, 14:09:54 PM
Hi Jose-Carlos!

As this is triggered by the Forms plugin I redirected your bug report back to the original report:

https://github.com/archi-contribs/form-plugin/issues/27

8)

Phil
Title: Re: Form plugin: org.eclipse.swt.SWTError: No more handles
Post by: Phil Beauvoir on May 27, 2019, 14:14:58 PM
It could be caused by too many UI elements. It might be worth experimenting with smaller amounts of data to see if this is the cause.

When I do a Google search for "org.eclipse.swt.SWTError: No more handles" it seems to be lack of memory or too many UI elements. For example:

https://developer.ibm.com/answers/questions/378241/what-is-the-cause-of-the-orgeclipseswtswterror-no/
Title: Re: Form plugin: org.eclipse.swt.SWTError: No more handles
Post by: Jose-Carlos on May 27, 2019, 14:48:21 PM
Thanks for your answer.
I have made some tests based on your link.
When monitoring USER handles for Archi.exe process, during the form build, the limit of 10000 is reached. This is a Windows manager limit which cannot be changed: https://blogs.technet.microsoft.com/markrussinovich/2010/02/24/pushing-the-limits-of-windows-user-and-gdi-objects-part-1/ (https://blogs.technet.microsoft.com/markrussinovich/2010/02/24/pushing-the-limits-of-windows-user-and-gdi-objects-part-1/).

So, I need to reduce the number of elements concerned by this form configuration in a single view to avoid this issue.
Title: Re: Form plugin: org.eclipse.swt.SWTError: No more handles
Post by: Phil Beauvoir on May 27, 2019, 15:31:40 PM
That might be a short term solution. In the long term it may be that the Form code needs to be optimised. For Herve this may be the issue https://github.com/archi-contribs/form-plugin/issues/27#issuecomment-496213823
Title: Re: Form plugin: org.eclipse.swt.SWTError: No more handles
Post by: Hervé on May 28, 2019, 19:47:02 PM
Thanks Phil,

I'll rewrite my code accordingly.

Best regards
Hervé