Bug 24346 - Error when xsl file size is too large (+/- 850 lines)
Summary: Error when xsl file size is too large (+/- 850 lines)
Status: CLOSED FIXED
Alias: None
Product: Fop - Now in Jira
Classification: Unclassified
Component: pdf (show other bugs)
Version: 0.20.5
Hardware: PC All
: P3 blocker
Target Milestone: ---
Assignee: fop-dev
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-03 10:06 UTC by Michel
Modified: 2012-04-01 07:01 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michel 2003-11-03 10:06:35 UTC
Error when xsl file size is too large (+/- 850 lines)
Convertion works fine till the size of the XSL file (not XML file) reach a 
certain value.

Error : java.io.UTFDataFormatException: invalid byte 3 of 3-byte UTF-8 sequence
Command line : call %FOP_DIR%\fop -xml %FAC_DIR%\XML\%1 -xsl %FAC_DIR%\xsl\e-
Yel_Factures_DET_RES.xsl -pdf
Comment 1 J.Pietschmann 2003-11-03 13:34:34 UTC
Well, the error message clearly indicates this is an encoding problem and has
absolutely nothing to do with the size of the XSL file or whatever.
The most common cause that the editor saves the file ISO-8859-1 encoded while
there wa no encoding declaration, causing the parser to assume UTF-8 encoding.
I suspect there are a few french characters in the file. Delete the offending
characters (in an XML comment) or replace them with XML character references
(in normal content) or declare the proper encoding in the XML declaration.
Comment 2 Michel 2003-11-03 13:44:07 UTC
Thanks, but your explanation is not correct, the problem has nothing to do 
(directly) with UTF8.  My temporary solution is to split the xsl file into 2 
files.  And it works! The problem is that I must launch 2 processes to generate 
my PDF doc and the page numbering is not linked (of course).

It's clearly a problem of space (memory process ??)



Comment 3 Konstantin Kolinko 2003-11-03 14:44:11 UTC
A workaround may be to do XSL transformation as a separate step.

Step 1. Use Xalan to transform your XML through your XSL, to get an XML:FO 
formatted file.
Step 2. Feed the resulting file to FOP to generate your PDF.

(If step 1 fails, the problem is with your files).
Comment 4 Michel 2003-11-03 15:11:09 UTC
Wonderfull Konstantin !

It solves the problem.
I'm not sure, but could it be more quick than before (use of fop -XML, -XSL)? 
You know what ? I'm happy.

Thanks.
Comment 5 Glenn Adams 2012-04-01 07:01:30 UTC
batch transition pre-FOP1.0 resolved+fixed bugs to closed+fixed