> I was just looking at the FOP API JavaDocs.  Can I use getContentHanlder from the 
>Driver object, send that
> into the transformer wrapped in a SAXResults object?  Will this populate FOP with 
>the required data to do
> the XSL:FO transform?

You got it!!!!! That's just what I was about to suggest.

> On Fri, Mar 22, 2002 at 11:22:12AM -0500, David B. Bitton wrote:
> > 1000/N
> > Status: O
> > X-Status: 
> > X-Keywords:                  
> > X-UID: 600
> > 
> > Ok this is what I'm doing:
> > 
> > I produce an XML file from data stored on a mainframe.  The XML is generate in a 
>VB object.  The XML is
> > passed up to an ASP page that makes a Low Level API SOAP call, using MSSOAP 
>Toolkit 2.0,  to my PDF server.
> > The PDF server is running Tomcat 4/Apache SOAP 2.2.

Concerning Apache SOAP 2.2: You might want to have a look at Axis
(http://xml.apache.org/axis) which is a floolow-on for SOAP 2.2. I think
I heard once that it is based on SAX rather than DOM. Haven't tested it,
though.

> > 
> > On the PDF server, I receive the XML as literalxml in the envelope, fetch a 
>stylesheet, pass the Element
> > object to a Xalan 2.3 transformer (wrapped in a DOMSource object), and then 
>transform the XML into XSL:FO
> > objects.  
> > 
> > Now I have a Document object that was returned from the transformer wrapped in a 
>DOMResults object.  The
> > next step is where the problem lies.  I want to pass the Document to a Driver, but 
>I get the dreaded
> > NullPointerException.
> > 
> > Most of the time, the XML is will be small ( 5 - 7K), but there is a potention for 
>an account to have 5 to
> > 10 thousand transactions in a day, and we store up to 63 days of data (a single 
>transaction in XML is 594
> > bytes, therefore a 630K transaction XML file would be 374MB, plus some extra data 
>at the top).  So you can
> > see what I have the potential to deal with.
> > 
> > What I don't even know is how FOP will handle this.  The XSL:FO file is sure to be 
>much larger than 380MB.
> > I transformer a 6.66KB XML file and it produced a XSL:FO file of 16.2KB.  If we 
>use that as a benchmark,
> > than the same 374MB would become 909.8MB.  That's a whole lot of RAM, not to 
>mention what FOP is going to
> > use to store the rendered PDF.

I hope you will be lucky. Some have reported that big documents work
well. Others were not so lucky. As long as there are not many references
in your documents you should get quite far. You can browse the archives.
There has been a number of discussions on this topic.

> > I'm hoping that someone can poke a hole in these numbers (please), because this is 
>getting to look a whole
> > lot bigger than expected.  Obviously performance and resource utilization are 
>major concernes (like when are
> > they not?).  Obviously SAX for this would be faster because it wouldn't require 
>loading the entire XML
> > contents into memory.
> > 
> > So, now is here the questions come in.  Do I return from the transform a 
>SAXResults?  Also, how do I
> > effectively handle the incoming XML into the SOAP method?  I would prefer to send 
>the XML in literalxml
> > format so the < and > are HTML encoded (increasing the size of the content even 
>more).
> > 
> > Where do I go from here?
> > 
> > 
> > On Fri, Mar 22, 2002 at 04:49:40PM +0100, Jeremias Maerki wrote:
> > > <comment>Oops, that one didn't make it to the list at first.</comment>
> > > 
> > > DOM (Document) should work. But using DOM to process a 400MB XML? You
> > > wouldn't want to do that. Try to find a way to use SAX. You can fill SAX
> > > events into FOP to create the FO tree. Maybe it helps us to provide you
> > > with some pointers and ideas if you tell us what exactly you're trying
> > > to do.
> > > 
> > > >         I'm sorry to post this again but I need help.  Does passing a Document 
>datatype to the Driver
> > > > render() method work?  I have to potential to move XML files in excess of 
>400MB and so I need to avoid as
> > > > moving of data in memory as possible.

Cheers,
Jeremias Märki

mailto:[EMAIL PROTECTED]

OUTLINE AG
Postfach 3954 - Rhynauerstr. 15 - CH-6002 Luzern
Tel. +41 41 317 2020 - Fax +41 41 317 2029
Internet http://www.outline.ch


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to