incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul Davis" <>
Subject Re: Document Updates
Date Thu, 13 Nov 2008 19:06:30 GMT
On Thu, Nov 13, 2008 at 11:43 AM, Noah Slater <> wrote:
> On Thu, Nov 13, 2008 at 06:40:44PM +0200, Ayende Rahien wrote:
>> I think that this should be pretty easily done using:
>> a) well defined pretty format output
>> b) standard diff
>> The reason for (a) is that you need this to get line breaks, which are
>> critical to diffing correctly.
> It's a bit more complex than that, canonicalised JSON is still in it's infancy,
> so we would have to get the community to adopt that first. I know that people
> have been discussing JSON diffs before, may be worth looking up what's already
> been done on this.
> --
> Noah Slater,

I think the JSON diff is a great idea. Unfortunately, the RFC is a bit
worrisome in one respect:

Section 2.2:
'The names within an object SHOULD be unique.'

I think that this could be a pretty big stumbling block if different
parsers start taking different interpretations of that and I've alread
seen implementations do slightly different things with repeated field

Contemplating the canonical spec I think I would prefer updating the
JSON spec's use of SHOULD to MUST. The canonical thing to me seems
more like a normalization method as opposed to a hard and fast spec.
Specifically I could see lots of wasted cycles spent on keeping
canonization when it's needed relatively infrequently.

Assuming the change to MUST, I could probably write and implement a
first draft of the spec in a day.

How hard can it be to change an RFC?


View raw message