Menu

#1096 SWTError: No more handles on Violation Outline View

Eclipse-Plugin
closed
Eclipse
2-Critical
Bug
5.0.4
2013-08-22
2013-05-17
No

I'm experiencing an issue just like the one described in the previously closed ticket #560. I'm running Windows 7 Enterprise. I'm using the Spring Tool Suite 3.2.0.RELEASE (bundled with Eclipse Juno 4.2.2 win32-x86) and the latest PMD plugin for Eclipse (4.0.0.v20130510-1000) obtained from the update site.

The Violation Outline View causes Eclipse to throw a SWTError: No more handles. This error does not produce an error box or message, just a new entry of this error in the Eclipse log each time the Eclipse window is clicked. This bug causes my Eclipse to entirely freeze up. I have to end the process manually through the Task Manager and restart Eclipse to fix the issue, but the issue will occur again after using Eclipse for only a minute or two. In this state, I cannot use the PMD plugin as it renders my Eclipse environment virtually unusable.

Some statistics:
Projects in displayed working set: 43
Projects in the Violations Overview: 2
No. of violations in Overview Panel (mostly all collapsed): about 3,500

This problem seems to occur when the Violations Outline view has to be refreshed. I'm not familiar at all with how Eclipse is developed, but it seems like PMD is either not releasing these "handles" on each refresh or is requesting too many. Apologies that I cannot be more resourceful. If there's anything further I can provide, please just ask because I'd really love to be able to use this plugin.

1 Attachments

Discussion

  • Jeff Yankowski

    Jeff Yankowski - 2013-05-17

    Apologies for the large text and possible incorrect module assignment (probably should be Eclipse). First time poster of Sourceforge and apparently I'm either blind or I'm not permissioned to edit my own ticket. First time woes.

     
  • Andreas Dangel

    Andreas Dangel - 2013-05-20
    • Module: PMD --> Eclipse
    • Milestone: New Tickets --> Eclipse-Plugin
     
  • Jeff Yankowski

    Jeff Yankowski - 2013-05-20

    Thank you, Andreas. I will definitely track that thread as well as it definitely seems related to the issue that I'm experiencing. For the time being, it looks like I can create the custom perspective, but the I did find the outline view to be the most useful, so I hope it's not too hard to fix :).

     
  • Andreas Dangel

    Andreas Dangel - 2013-05-22
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -5,7 +5,7 @@
     Some statistics:
     Projects in displayed working set: 43
     Projects in the Violations Overview: 2
    -# of violations in Overview Panel (mostly all collapsed): about 3,500
    +No. of violations in Overview Panel (mostly all collapsed): about 3,500
    
     This problem seems to occur when the Violations Outline view has to be refreshed. I'm not familiar at all with how Eclipse is developed, but it seems like PMD is either not releasing these "handles" on each refresh or is requesting too many. Apologies that I cannot be more resourceful. If there's anything further I can provide, please just ask because I'd really love to be able to use this plugin.
    
     
  • Andreas Dangel

    Andreas Dangel - 2013-08-07
    • status: open --> in-progress
    • assigned_to: Andreas Dangel
     
  • Andreas Dangel

    Andreas Dangel - 2013-08-09

    I found the class - it's the ShapePainter. There we create the little images that represent the rule priority for the violations. We always create new images and don't dispose them - that's the leak.

    I could fix this by caching the images (we have only a limited number of different rule priorities and images). This is probably not a elegant solution, but at least we don't leak resources anymore. Better solution would be probably something like a resource manager with reference counting and disposing the images as soon as they are not needed anymore.

    By the way, a nice tool to find the resource leaks, is Sleak - part of the SWT Tools: http://www.eclipse.org/swt/tools.php

     
  • Andreas Dangel

    Andreas Dangel - 2013-08-11
    • status: in-progress --> closed
     
  • lhasadad

    lhasadad - 2013-08-22

    I tried the new plugin yesterday and this appears to be resolved.

     

Log in to post a comment.