[xsl] saxon:next-in-chain and memory usage

Subject: [xsl] saxon:next-in-chain and memory usage
From: "Frederik Fouvry frederik.fouvry@xxxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Wed, 9 Nov 2016 12:56:57 -0000
Hello,

I am running a pipeline of XML transformations over an XML file of about 130Mb, using Saxon 9.1.0.5J and Java 1.8.0_112. The pipeline is implemented using saxon:next-in-chain. It works fine as long as I have fewer than about five steps, but when I have five or more, then Java runs out of memory, regardless of the complexity of the style sheets (as the simplest, I tried the identity transformation). Is this to be expected? Is the result of each step kept in memory? Or is it due to something else?

Giving Java more memory seems to help in some cases, but because the size of the file can vary a lot (mostly it will be smaller, but in some cases, it may be bigger), that is not a scalable solution.

Many thanks,

Frederik Fouvry
Current Thread