When using lots of images, FOP consumes lots of memory because the image cache is not cleared. Further, streams are not closed properly when loading images.
Created attachment 14622 [details] The image cache gets a min, minsize, max and maxsize paramters; streams are closed The patch has been tested in production heavliy.
*** Bug 30156 has been marked as a duplicate of this bug. ***
Created attachment 14629 [details] src/org/apache/fop/image/ImageCacheEntry.java The file was missing from the patch because there seems to be no way to get a "cvs diff" with new files which have not been added to CVS yet (because I've got no write access).
Created attachment 15661 [details] Improved patch for an LRU cache which cleans up Now complete patch, with ImageCacheEntry and everything. It has also been reworked to use a LinkedHashMap for storing the cache entries. Further, a setCacheMap method has been added (this will be used within http://www.open-eis.com/ to supply an implementation which integrates into the caching framework of open-EIS).
Timo, We do not apply patches to the 0.20.5 branch. IIRC, on the development branch work has been done on image caching. If you feel that your work is useful for the development branch as well, we will be grateful for a new patch. Simon
Sorry, we're not going to use the new FOP anytime soon, so I cannot test it. If we switch to the new FOP, we'll probably take care of this.
batch transition to closed remaining pre-FOP1.0 resolved bugs