Re: JSON for PG 9.2

From: Merlin Moncure <mmoncure(at)gmail(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, dimitri(at)2ndquadrant(dot)fr, Jan Urbański <wulczer(at)wulczer(dot)org>, Robert Haas <robertmhaas(at)gmail(dot)com>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Joey Adams <joeyadams3(dot)14159(at)gmail(dot)com>, Bruce Momjian <bruce(at)momjian(dot)us>, Claes Jakobsson <claes(at)gluefinance(dot)com>, PostgreSQL-development Hackers <pgsql-hackers(at)postgresql(dot)org>, Jan Wieck <janwieck(at)yahoo(dot)com>
Subject: Re: JSON for PG 9.2
Date: 2011-12-18 17:34:21
Message-ID: CAHyXU0y4WxeT1Y+y-yCgj5scNb7nN_tNFTmurpMLFJKoshV5GA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, Dec 18, 2011 at 11:21 AM, Andrew Dunstan <andrew(at)dunslane(dot)net> wrote:
>
>
> On 12/18/2011 12:17 PM, Merlin Moncure wrote:
>>
>> One small note about the json type being an extension -- this probably
>> means the json type oid won't be fixed -- not a huge deal but it could
>> affect some corner cases with binary format consumers.
>
> Why would that matter more for JSON than for any other non-core type?

well, it's a minor headache for all the oid-isn't-in-pgtypes.h types,
and only then for high traffic types (which presumably json will be).
a while back we coded up a reworked dblink that was variadic and
could optionally transfer data between database with the binary wire
format. any container of a user defined (by oid) type had to be sent
strictly as text which is a big performance hit for certain types.
recent postgres has an undocumented facility to force type oids to a
particular value, but the type definition being inside the create
extension script makes this problematic.

this is a pretty far out objection though, and I could certainly work
around the problem if necessary, but there is some dependency on
pg_types.h in the wild.

merlin

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dimitri Fontaine 2011-12-18 18:26:38 Re: JSON for PG 9.2
Previous Message Andrew Dunstan 2011-12-18 17:21:24 Re: JSON for PG 9.2