Red Hat Bugzilla – Bug 976897
Excessive Heap Consumption in com.sun.imageio.plugins.jpeg.JPEGImageWriter
Last modified: 2013-12-12 14:10:17 EST
Created attachment 763948 [details]
Description of problem:
After upgrading to java-1.6.0-openjdk-184.108.40.206-220.127.116.11.11.el6_4.x86_64, Java applications are consuming more memory (specifically int objects allocated by com.sun.imageio.plugins.jpeg.JPEGImageWriter), without releasing it.
Version-Release number of selected component (if applicable):
Easily reprocible with a test case.
Steps to Reproduce:
1. Compile and run Prueba.java (attached in bz)
2. Use the following VM parameter: -Xmx64m
3. Use the following Program Parameter: 1000
It throws a OOME Heap Size Exception
Allocate objects and print memory information
Created attachment 767894 [details]
Java 7 compatible test-case
Created attachment 767905 [details]
Fix has been committed upstream in the 8 branch:
I'll ask the backport on 6 and 7 now.
The fix has been backported to 7, I'm awaiting the backport to 6 now.
I have backported the patch for 6 myself, here is the RFC:
And here the patch:
Waiting for reviewer's approval now.
The fix is in 8 and 7, and is going to 6. I will include the patch to RPMs directly to speed up escalation.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
Note this leak also impacted RHEL 5's open jdk (java-1.6.0-openjdk-18.104.22.168-22.214.171.124.11.90.el5_9) but appears to have been fixed as well (java-1.6.0-openjdk-126.96.36.199-188.8.131.52.14.el5_10)