JDK-2191145 : OutOfMemory (PermGen space) under Linux / Firefox when switching bw. applets
  • Type: Backport
  • Backport of: JDK-6773985
  • Component: client-libs
  • Sub-Component: java.awt
  • Priority: P2
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2010-04-05
  • Updated: 2011-01-19
  • Resolved: 2010-04-12
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7
6u21 b03Fixed 7Fixed
Description
Igor Nekrestyanov wrote:

> Context:
>    Reloading same FX applet every 5 sec will cause OOM as classes/static state are not released
> (using old plugin to reproduce faster).
>
> Here is the interesting part of reference chains (look for who is holding PluginClassLoaders):
>
> --> sun.awt.X11.XToolkit@0x8bce03d0 (71 bytes) (??:)
> --> class sun.awt.X11.XToolkit (84 bytes) (static field winToDispatcher:)
> --> java.util.HashMap@0x8bce2908 (40 bytes) (field table:)
> --> [Ljava.util.HashMap$Entry;@0x8e4760f8 (136 bytes) (Element 3 of [Ljava.util.HashMap$Entry;@0x8e4760f8:)
> --> java.util.HashMap$Entry@0x8cb36328 (24 bytes) (field value:)
> --> java.util.Vector@0x8cb37ef0 (24 bytes) (field elementData:)
> --> [Ljava.lang.Object;@0x8cb3a0f0 (48 bytes) (Element 0 of [Ljava.lang.Object;@0x8cb3a0f0:)
> --> sun.awt.X11.XEmbedClientHelper@0x8cb395f8 (22 bytes) (field embedded:)
> --> sun.awt.X11.XEmbeddedFramePeer@0x8cb373a8 (305 bytes) (field target:)
> --> sun.plugin.viewer.frame.XNetscapeEmbeddedFrame@0x8cb35718 (424 bytes) (field appContext:)
> --> sun.awt.AppContext@0x8cb363b0 (49 bytes) (field contextClassLoader:)
> --> sun.plugin.security.PluginClassLoader@0x8cb34ad0 (124 bytes) (field classes:)
>
> To reproduce the problem you can try reloading one of the JavaFX samples with the latest build.
> E.g. ProjectManager one. (use link for samples)
>
> Origin             : RE
> Product            : javafx 1.3
> TYPE               : Weekly promotion
> Version            : fcs build b32
> Date               : Fri Apr  2 00:28:20 2010
> Binaries           : /java/re/javafx/1.3/promoted/fcs/b32/binaries
> Bundles            : /java/re/javafx/1.3/promoted/fcs/b32/bundles
> *Bundles URL       :http://jre.sfbay.sun.com/java/re/javafx/1.3/promoted/fcs/b32/bundles
> Workspace          : /java/re/javafx/1.3/promoted/fcs/b32/ws
> dtfx.js            :http://jfx.sfbay.sun.com:5001/1.3.0_b32/dtfx.js
> javafx-rt.jnlp     :http://jfx.sfbay.sun.com:5001/1.3.0_b32/javafx-rt.jnlp
> jcov instrumented  :http://jre.sfbay.sun.com/java/re/javafx/1.3/promoted/fcs/b32/bundles/*/*-instr.zip
> compatibility build:http://jfx.sfbay.sun.com/hudson/job/soma-compatibility/
> samples build      :http://fxsqe.sfbay.sun.com/jfxsamples/1.3.0/b32/
>
> You should probably see this with any regular applets too.

Comments
SUGGESTED FIX http://sa.sfbay.sun.com/projects/awt_data/6u20/6773985
05-04-2010

EVALUATION See parent CR.
05-04-2010