You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by "Vincent Bonnefoy (JIRA)" <ji...@apache.org> on 2018/01/08 07:36:00 UTC

[jira] [Commented] (FOP-2762) Serialisation issues when Accessibility is turned on

    [ https://issues.apache.org/jira/browse/FOP-2762?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16315790#comment-16315790 ] 

Vincent Bonnefoy commented on FOP-2762:
---------------------------------------

[~lancess]
We are processing very large documents with more than 5k pages, the conserve memory flag is a must have otherwise FOP keeps the whole tree structure into memory an run out of it very quickly.

> Serialisation issues when Accessibility is turned on
> ----------------------------------------------------
>
>                 Key: FOP-2762
>                 URL: https://issues.apache.org/jira/browse/FOP-2762
>             Project: FOP
>          Issue Type: Bug
>          Components: renderer/afp, renderer/pdf
>    Affects Versions: 2.1, 2.2
>            Reporter: Vincent Bonnefoy
>         Attachments: cfg-accessibility.xml, name.xml, name2fo.xsl, stacktrace-intermediate-fo-afp.txt, stacktrace-intermediate-fo-pdf.txt, stacktrace-pdf.txt
>
>
> When rendering PDF or AFP using the conserve-memory and accessibility flag "on" a serialisation error is thrown.
> I'm using the "representation of document in intermediate format XML" and get the following error when the CachedRenderPagesModel.java class is trying to save the page to disk.
> {code:java}
> SEVERE: Error while serializing page 1. Reason: java.io.NotSerializableException: org.apache.fop.render.intermediate.IFStructureTreeBuilder$IFStructureTreeElement
> java.io.NotSerializableException: org.apache.fop.render.intermediate.IFStructureTreeBuilder$IFStructureTreeElement
> {code}
> It then leads to a NullPointerException when later the process tries to retrieve the page.
> I saw the same behaviour when the output is set as "pdf" and uses the PDFStructElem.java object even though that's not the mode I'm using that also needs to be fixed.
> {code:java}
> SEVERE: Error while serializing page 1. Reason: java.io.NotSerializableException: org.apache.fop.pdf.PDFStructElem$Placeholder
> java.io.NotSerializableException: org.apache.fop.pdf.PDFStructElem$Placeholder
> {code}
> I'm using fop within a java application but I reproduced using fop binaries:
> - name.xml - _comes from the fop website_
> - name2fo.xsl - _comes from the fop website_
> A page citation reference has been added +to force the conserve-memory flag to serialise the page to disk+ for unresolved references.
> - cfg-accessibility.xml - _comes from the fop website_
> 2 renderer have been added, PDF and AFP, since that's the ones I'm using.
> The <accessibility>true</accessibility> flag has been turned on
> fop -xml name.xml -xsl name2fo.xsl -c cfg-accessibility.xml out.pdf -conserve



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)