Re: JSON for PG 9.2 - Mailing list pgsql-hackers

From David E. Wheeler
Subject Re: JSON for PG 9.2
Date
Msg-id 33523926-C8CA-4DAE-A709-B0F6D87BA22D@justatheory.com
Whole thread Raw
In response to Re: JSON for PG 9.2  (Peter van Hardenberg <pvh@pvh.ca>)
Responses Re: JSON for PG 9.2  (Jan Urbański <wulczer@wulczer.org>)
List pgsql-hackers
On Dec 12, 2011, at 4:51 PM, Peter van Hardenberg wrote:

> Because we haven't heard from him in a while we've been using PL/V8 to
> validate a JSON datatype simulated by a DOMAIN with a simple
> acceptance function. (See below.) This is not ideally performant but
> thanks to V8's JIT the JSON parser is actually reasonably good.
>
> I think releasing something simple and non-performant with reasonable
> semantics would be the best next step. If it were up to me, I'd
> probably even try to just land PL/V8 as PL/JavaScript for 9.2 if the
> crash bugs and deal breakers can be sifted out.

Note that Claes Jakobsson has been working on a JSON data type using the Jansson JSON library.
 http://pgxn.org/dist/pg-json/

I’ve submitted a pull request renaming it to jansson-json (though the data type is still "json"):
 https://github.com/theory/pg-json/tree/pgxn

Anyway, it seems like a decent start to an extensible type implemented entirely as an extension. Claes tells me he
plansto add index support soonish, so it could get to be pretty robust before long. 

Just another stab at the problem to alert folks to.

Best,

David



pgsql-hackers by date:

Previous
From: "David E. Wheeler"
Date:
Subject: Re: WIP: URI connection string support for libpq
Next
From: Andrew Dunstan
Date:
Subject: Re: JSON for PG 9.2