xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexios Giotis <alex.gio...@gmail.com>
Subject Re: Memory leak in FOP
Date Thu, 08 Sep 2011 09:09:03 GMT
Hi Jonathan,

We are running FOP multi-threaded in many production systems. Each system is creating thousand
documents per day (typically 100 -500 thousand PDFs) and I have not noticed any memory leak.
Having said that, our servers are running with large memory heaps (6-10GB), FOP uses a lot
of memory for large documents and internal caches for performance.

If you are going to use it at production, I would recommend not to share the same FopFactory
instance between threads. It is supposed to the thread-safe but we found (and in most cases
fixed in trunk) several issues. You could try the FOP trunk or you could apply the patches
for the related issues in your own private branch (this is what we do). Some issues that I
remember:

https://issues.apache.org/bugzilla/show_bug.cgi?id=50698  (starting from http://marc.info/?l=fop-user&m=129646673801270&w=2)
https://issues.apache.org/bugzilla/show_bug.cgi?id=46360

and lately a deadlock that I am waiting for someone to review the patch:
https://issues.apache.org/bugzilla/show_bug.cgi?id=46962

Best Regards,
Alexis Giotis





On Sep 7, 2011, at 7:31 PM, Jonathan Levinson wrote:

> To speed up FOP rendering, I have developed a multi-threaded program that initializes
a FOP factory and shares it amongst the thread instances.
>  
> We experience a large performance increase because we are not starting a JVM on each
instance of FOP rendering and we are not creating a FOPFactory for each thread but sharing
a FOPFactory amongst threads.
>  
> Testing on LINUX and using the following command to examine memory:
>  
> ps -e -orss=,args= | sort -b -k1,1n | pr -TW$COLUMNS
>  
> I notice a slow memory memory leak.
>  
> The test sends the same xml and xsl over and over again to the same multi-threaded program
with its FOP factory instance.
>  
> Is this a well known problem in FOP?  Does FOP leak memory?
>  
> Best Regards,
> Jonathan Levinson
>  


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Mime
View raw message