Re: issue 85 - range unit extensions

Kris Zyp wrote:
> >I'm a bit surprised that the top-level object in a JSON request would
> >be an array, though.  For round-trip minimisation in AJAX applications
> >isn't it usual to send a bit of auxiliary metadata, or a few objects
> >together, and therefore the top-level JSON object tends to be an
> >object (i.e. several named data items) with one of its members being
> >an array, rather than the top-level object being an array itself?
> I am trying to move away from that approach, moving metadata to headers 
> (ironically the offset and total count are the most common metadata items, 
> and these are handled by the Content-Range header), allowing the actual 
> content to be a "pure" representation of the resource, and therefore an 
> array is the most natural top-level construct when requesting a collection 
> of objects.

Unfortunately, putting metadata into headers isn't a very tidy way of
representing metadata which has structure itself, which is not
uncommon with JSON.

-- Jamie

Received on Tuesday, 2 September 2008 23:24:45 UTC