I was quite concerned when I couldn't find a formal specification for the simple newline delimited JSON over TCP framing (which I have successfully used on multiple projects).So I wrote one:Have I missed a IETF or W3C RFC for this?
On Tue, Jun 11, 2013 at 8:57 AM, Chris Dew <cms...@gmail.com> wrote:I was quite concerned when I couldn't find a formal specification for the simple newline delimited JSON over TCP framing (which I have successfully used on multiple projects).So I wrote one:Have I missed a IETF or W3C RFC for this?Hey Chris,I think most streaming parsers just wait for the beginning object or array to close and don't necessarily need a delimiter between objects.A lot of work in "streaming JSON over TCP" has been focused on binary serialization formats as a whole, not necessarily chunk delimiters.
That makes sense.I get that it's a lot simpler to implement, but I'm often in a position where I need a full-blown transfer protocol.In HTTP, for instance, not only can I receive multipart content that defines boundaries separating each JSON object, but I can also get helpful metadata like Content-Length, Content-Encoding, etc. (Granted, using this also ties one into a request/response model with the overhead of an HTTP parser.)I'm curious what your use cases are for character-delimited JSON objects over-the-wire. (I can speculate, but I find the real world is usually more interesting.)
--
--
Job Board: http://jobs.nodejs.org/
Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to nod...@googlegroups.com
To unsubscribe from this group, send email to
nodejs+un...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en
---
You received this message because you are subscribed to the Google Groups "nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+un...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.