I am currently using result-document() to write the results of an XSLT processing chain to file.

Ideally, I would like to run several of these processing chains in parallel, with all of them writing to the same file.

The order of results doesn't matter; what does matter is that the results be output in a clean and non-conflicting manner.

My question accordingly is - what guarantees are there that xsl:result-document() will read and write properly when used concurrently? Is file-locking in place? Or is there a risk of mistimed read and write operations leading to a banjaxed output file.

I'm using Saxon 9.5 HE.

Thanks,

Tim Hill