Live data from Hacker News

JSON Patch – a format for describing changes to a JSON document

jsonpatch.com

111–112 of 112 posts

Re: JSON Patch – a format for describing changes to a JSON document

#111
post #77
post #6

The op missing is string diff. If a very long string value has changed, no matter how little the change is, you'll have to include the entire string in the patch.

That would be really useful for some things. Quite a burden to put on the library implementors though!

Let's say you want to update a typo in a lengthy document, I think it's worth the trouble. Good diff algorithm is hard, but there is open source solution.

http://code.google.com/p/google-diff-match-patch

Re: JSON Patch – a format for describing changes to a JSON document

#112
post #110

Earlier quoted context omitted.

But its Javascript Object Notation - Notation in this case implies text - if your storing it in something other than text it's not JSON. From Wikipedia: JavaScript Object Notation, is an open standard format that uses human-readable text to transmit data objects consisting of attribute–value pairs.

Like you pointed out JSON is used to transmit data objects, but storage of data objects on the server or local file is entirely different story. I hope I don't have to explain further.

Yes, then its no longer json...
Post reply on HN