Optimizations and performance improvements
xsl:result-document instruction in Saxon-EE is now asynchronous. That is, the
code to output the result document runs in a separate thread, in parallel with other
processing. The maximum number of threads used by
is limited by the configuration option
which defaults to the number of processors available to the Java VM; setting this to zero or one will
suppress multithreading. Setting
FeatureKeys.ALLOW_MULTITHREADING to false has
the same effect. (This can be useful when debugging, because otherwise the output from
fn:trace() can be very confusing).
Asynchrony can also potentially cause problems if the code calls extension functions that
have side-effects. Multi-threading can therefore be controlled, if required,
saxon:asynchronous attribute on the
saxon:asynchronous="no" to suppress multi-threading.
Asynchronous processing of
xsl:result-document is automatically suppressed if
tracing (using a
TraceListener) is enabled.
collection() function is also now multi-threaded in Saxon-EE. Each document in the collection
is parsed in a separate thread, and the documents are processed in the order in which parsing completes. This
makes the order of the documents less predictable than in previous releases, though it was never guaranteed or