Hi Georg, As far as I'm understanding it, the transformation is the PDF creation?
The image cache is already cleared after each converted file. I'll search the list archive for other options. I was hoping for certain JVM settings which could increase the tenured memory pool size. Best regards, Dennis van Zoerlandt Georg Datterl wrote: > > Hi Dennis, > > Make sure you die during pdf creation, not during transformation. > Keep your page-sequences as short as possible. Starting a new > page-sequence releases memory used by previous page-sequence > If you have many images which are only used once, deactivate image cache. > This topic is fairly common in this list, so check the archive for > details. > > Regards, > > Georg Datterl > > ------ Kontakt ------ > > Georg Datterl > > Geneon media solutions gmbh > Gutenstetter Straße 8a > 90449 Nürnberg > > HRB Nürnberg: 17193 > Geschäftsführer: Yong-Harry Steiert > > Tel.: 0911/36 78 88 - 26 > Fax: 0911/36 78 88 - 20 > > www.geneon.de > > Weitere Mitglieder der Willmy MediaGroup: > > IRS Integrated Realization Services GmbH: www.irs-nbg.de > Willmy PrintMedia GmbH: www.willmy.de > Willmy Consult & Content GmbH: www.willmycc.de > > -----Ursprüngliche Nachricht----- > Von: Dennis van Zoerlandt [mailto:[email protected]] > Gesendet: Freitag, 25. März 2011 09:51 > An: [email protected] > Betreff: OutOfMemoryException while transforming large XML to PDF > > > I get a OutOfMemoryException (Java heap space) while transforming a > relatively large XML (10 MB) with a XSL-FO to a PDF file. I'm using these > steps for the transformation: > > --- > FOUserAgent userAgent = fopFactory.newFOUserAgent(); > Fop fop = this.fopFactory.newFop(MimeConstants.MIME_PDF, userAgent, out); > TransformerFactory factory = TransformerFactory.newInstance(); > Transformer transformer = factory.newTransformer(new > StreamSource(xslFile)); > transformer.setParameter("versionParam", "2.0"); > Source src = new StreamSource(xmlFile); > Result res = new SAXResult(fop.getDefaultHandler()); > transformer.transform(src, res); > --- > > I have tried to increase the initial and maximum heap size (with options > -Xms and -Xmx) at JVM startup but with no success. While transforming, I'm > monitoring the size of the used and maximum tenured generation memory > pool. > The options don't seem to affect the tenured pool size: this pool is > continuously getting full in 3, 4 minutes which results shortly after that > in this exception. > > What are my options to prevent the OutOfMemoryException? > > Best regards, > Dennis van Zoerlandt > -- > View this message in context: > http://old.nabble.com/OutOfMemoryException-while-transforming-large-XML-to-PDF-tp31236044p31236044.html > Sent from the FOP - Users mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > > -- View this message in context: http://old.nabble.com/OutOfMemoryException-while-transforming-large-XML-to-PDF-tp31236044p31236224.html Sent from the FOP - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
