Loading ...
Sorry, an error occurred while loading the content.

1983RE: [json] Introducing Oboe.js - streaming JSON loading in Javascript

Expand Messages
  • Yasser Asmi
    Feb 10, 2014
    • 0 Attachment
      Hi Jim

      This looks very interesting.   I will try it soon.

      Very well done web site.   Though one thing I had a hard time is finding how the code is licensed...

      Where does the name Oboe come from?


      From: jim.higson@...
      To: json@yahoogroups.com
      Date: Mon, 10 Feb 2014 02:43:25 -0800
      Subject: [json] Introducing Oboe.js - streaming JSON loading in Javascript

      I'd like to introduce my new streaming JSON project. I wrote this project as my Master's dissertation having found no completely satisfactory library for loading large JSON resources. It has been listed on json.org and available through Github for some time but last week I launched a website for the project.

      The website is here: http://oboejs.com

      The idea is that JSON can be read as a streaming format. The "stream effect" may be because of network bandwidth, or because the server is writing out the JSON as a stream. The library also in some cases simplifies finding particular features in a JSON file, for example by allowing Duck Typing to be used.

      This differs from most 'streaming JSON' projects in that the JSON format does not have to be specially designed for streaming - any valid JSON works and can be read as a stream. For example, on a mobile network a server might write out the JSON in one big lump, unaware that a streaming parser will be used, but it will still arrive as several small parts.

      Essentially, Oboe.js is like a SAX parser but with a much higher-level interface. SAX is very light on resources but programming with it is a lot of work and it is easy to make mistakes. Oboe.js replaces programmatic searching for nodes inside the JSON with simple pattern-based node detection. Internally, Oboe.js uses the Clarinet JSON SAX parser and (in the browser) takes input from XHR2 progress events.

      There is a page here which uses animated visualisations to illustrate how streaming JSON can improve the performance of web applications:


      Hope you find this interesting,

    • Show all 4 messages in this topic