This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 29467 - [xslt30] Non-streaming fallback implementation of xsl:stream
Summary: [xslt30] Non-streaming fallback implementation of xsl:stream
Status: CLOSED WORKSFORME
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XSLT 3.0 (show other bugs)
Version: Candidate Recommendation
Hardware: PC All
: P2 normal
Target Milestone: ---
Assignee: Michael Kay
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-02-15 17:36 UTC by Michael Kay
Modified: 2016-10-06 18:42 UTC (History)
0 users

See Also:


Attachments

Description Michael Kay 2016-02-15 17:36:03 UTC
It would often be useful to be able to execute an xsl:stream instruction in fallback mode when the processor does not support streaming.
Comment 1 Michael Kay 2016-02-16 11:17:29 UTC
We found this Note in 18.1:

The name of the instruction reflects its intended usage, to process an input document using streaming. However, a processor that does not offer the streaming feature must still implement the instruction (without being required to use streamed evaluation or to check its streamability); and processors that do offer the streaming feature are also required to provide a mode of execution in which the construct is evaluated without streaming if it fails the streamability criteria.

Also noted that 19.10 says:

For a non-streaming processor, the processor must evaluate the construct delivering the same results as if execution used streaming, but with no constraints on the evaluation strategy.

It also says: "For a streaming processor, that is, a processor that claims conformance with the streaming feature: ... If a construct is guaranteed-streamable then it must be processed using streaming." 

So perhaps all that is needed is an API switch to say "run as a non-streaming processor"?

So we believe the requirement stated in this bug entry is already satisfied by the spec. A directive with similar effect within the stylesheet itself could be useful, but is not essential to meet the requirement.



Related to this (but not directly relevant...) is the rules for what a streaming processor must do when the construct is not streamable. In 19.10 we say

2(c) Process the stylesheet with streaming if it is able to do so, or signal a static error [see ERR XTSE3430] if it is not able to do so.

It might be useful to permit the processor to fail with a dynamic error if streaming is not possible (i.e. allow it to attempt streaming optimistically, wher e success or failure depends on the nature of the input data). E.g.

2(c) Initiate processing with streaming, raising a static error if it can determine statically that this will not be possible, or a dynamic error if the attempt to use streaming fails dynamically.

We will raise this as a separate issue, and close this one with no action.