[Bug 27107] New: [SER 3.1] Streamability of JSON Serialization method

https://www.w3.org/Bugs/Public/show_bug.cgi?id=27107

            Bug ID: 27107
           Summary: [SER 3.1] Streamability of JSON Serialization method
           Product: XPath / XQuery / XSLT
           Version: Working drafts
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Serialization 3.1
          Assignee: cmsmcq@blackmesatech.com
          Reporter: mike@saxonica.com
        QA Contact: public-qt-comments@w3.org

A point was made during discussion of bug 26784 which ought to be captured and
reviewed.

It was pointed out (I forget by whom) that the rule that a sequence of length 2
or more is serialized as a JSON array prevents streaming: if items in the
sequence are presented incrementally to the serializer, then it has to buffer
item 1 in memory (which might be arbitrarily large) so that it can prepend a
"[" in the case where a second item follows.

We should consider the alternative, of disallowing a sequence of length >1. A
more elaborate solution would be to handle a sequence of atomic values
according to the current rule (buffering a single atomic value is no problem),
but disallow sequences of length >1 if the first item is an array or map.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Monday, 20 October 2014 11:19:17 UTC