You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Matthew Langham <ml...@sundn.de> on 2000/12/04 09:48:33 UTC

FOP/PDF and C2 - Out of memory problems

We are running into "out of memory problems" using 0.14 and 0.15 fop with
small pdf documents in the current Cocoon 2 cvs release.

The problem arises after rendering several small pdf documents one after the
other. After a certain number of documents (differs depending on servlet
engine used and available memory) we get an "out of memory error".

Re: FOP/PDF and C2 - Out of memory problems

Posted by Fotis Jannidis <fo...@lrz.uni-muenchen.de>.
> We are running into "out of memory problems" using 0.14 and 0.15 fop with
> small pdf documents in the current Cocoon 2 cvs release.
> 
> The problem arises after rendering several small pdf documents one after the
> other. After a certain number of documents (differs depending on servlet
> engine used and available memory) we get an "out of memory error".
> 
> From previous postings in the fop-list this already seems to have been noted
> for large documents. Well several small ones seem to cause the same problem.
> 
> My questions are:
> 
> 1) Is this something already beeing fixed in fop [fop]?
> 2) Why is the memory not being cleaned up between documents [c2?]?
> 3) Are there any tips or tricks on how to reduce the memory used?
> 
> We are prepared to dig in to this ourselves - but we need some pointers.

I have no clear idea how Fop is integrated into Cocoon (probably 
having a own class calling Driver), so these are just wild guesses: If 
you look into XalanCommandLine, you see that - compared to 
CommandLine - the target Writer is explicitly closed; is this also in 
the Cocoon version?

You could add a reset method to Driver, which sets areatree and the 
others to null and is called at the end of processing the document. 

Fotis