[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Streaming with XSLT version 3.0
On Thursday, March 6, 2014 7:09 PM, Abel Braaksma (Exselt) <abel@xxxxxxxxxx> wrote: If I reformat your stylesheet (which somehow got corrupted ehaviliy on the mail server or on my client), I get the following (see below), which has everything inside xsl:stream commented out. Is that the one that causes you trouble (because an xsl:stream without a sequence constructor does nothing), or is it the one without the commented-out part? It is also important to try to find out what is actually causing the memory exception. If you run it from oXygen like you say, it is very well possible that the exception comes from oXygen itself, not capable of handling the output file. This would explain the late memory exception. To find this out, simply run it from the command line, and what what happens to memory in task manager. <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://www.mediawiki.org/xml/export-0.8/" xpath-default-namespace="http://www.mediawiki.org/xml/export-0.8/" exclude-result-prefixes="#all" version="3.0"> <xsl:output method="xml"/> <xsl:template name="main"> <xsl:stream href="../source/enwiki.xml"> <!-- <xsl:result-document href="../out/output-wiki-02.xml"> <xsl:for-each select="mediawiki"> <xsl:element name="mediawiki"> <xsl:for-each select="page[position() < 10]"> <xsl:copy-of select="."/> </xsl:for-each> </xsl:element> </xsl:for-each> </xsl:result-document>--> </xsl:stream> </xsl:template> </xsl:stylesheet> Cheers, Abel Braaksma http://exselt.net On 6-3-2014 13:58, Terry Badger wrote: > I have a 42 GB media and valid xml file as my source. I am using Oxygen 15.2 with Saxon ee 9.5.1.3. I am using this stylesheet which as you can see I turned off what I wanted to do to see if I could get to the end of the file. After about 45 minutes it hits my memory limit and quits. Am I doing this right or will I need to cut this elephant into pieces? > Terry > > <xsl:stylesheet > xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > xmlns:xs="http://www.w3.org/2001/XMLSchema" > xmlns="http://www.mediawiki.org/xml/export-0.8/" > xpath-default-namespace="http://www.mediawiki.org/xml/export-0.8/" > exclude-result-prefixes="#all" > version="3.0"> > <xsl:outputmethod="xml"/> > <xsl:templatename="main"> > <xsl:streamhref="../source/enwiki.xml"> > <!-- <xsl:result-document href="../out/output-wiki-02.xml"> > <xsl:for-each select="mediawiki"> > <xsl:element name="mediawiki"> > <xsl:for-each select="page[position() < 10]"> > <xsl:copy-of select="."/> > </xsl:for-each> > </xsl:element> > </xsl:for-each> > </xsl:result-document>--> > </xsl:stream> > </xsl:template> > </xsl:stylesheet> > > --~------------------------------------------------------------------ > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list > To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/ > or e-mail: <mailto:xsl-list-unsubscribe@xxxxxxxxxxxxxxxxxxxxxx> > --~-- Abel, I am running the saxon ee version inside Oxygen. I don't have a license for ee outside of Oxygen. I commented out the sequence constructor inside xsl:stream to see if that was causing me the problem and I did get a message after the out-of-memory that I should not expect any output. Terry
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|