Re: Postgresql 9.4 / JSONB / JDBC

From: Christopher BROWN <brown(at)reflexe(dot)fr>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Postgresql 9.4 / JSONB / JDBC
Date: 2014-12-29 10:08:25
Message-ID: CAHL_zcMdOoan=1UBYvA898EkoH70H_kk9iQbMDV7QnNT2=JzVg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Hello,

Regarding my previous messages on this subject (JSONB support in the
Postgresql JDBC driver), one assumption I'm making is that the driver might
be able to stream the JSON data more efficiently that just throwing a chunk
of text onto the wire... as text isn't the most efficient way of encoding
numbers, booleans, and nulls.

How does the native network protocol of Postgresql actually transfer such
data? Is there an opportunity for sending the data efficiently?
Personally for some of my applications, I'm able to use Jackson's "Smile"
binary JSON format, although I doubt that the Postgresql server would
understand it or want to implement it (I don't know if it could be
considered a standard, even if it's specified --
http://wiki.fasterxml.com/SmileFormatSpec).

--
Christopher

On 20 December 2014 at 10:44, Christopher BROWN <brown(at)reflexe(dot)fr> wrote:

> Hello,
>
> I'm new to this list, and have tried searching both the mailing list
> archives, and internet in general, for information on how to use the new
> JSONB data type with JDBC. Found almost nothing in the mailing list
> archives, and internet searches "helpfully" assume I've misspelled "json"
> and give me results that are unrelated or refer to the basic "JSON" type
> from older Postgresql versions.
>
> How can this type be used, with simple "flat" key-value collections
> (maps), with tree-like maps-of-maps, and (ideally) with JSON APIs such as
> Jackson JSON API?
>
> Is it possible? Is it already described somewhere that I missed?
>
> Thanks,
> Christopher
>

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Dave Cramer 2014-12-29 11:42:34 Re: Postgresql 9.4 / JSONB / JDBC
Previous Message Christopher BROWN 2014-12-29 09:53:16 Unregistering the driver from DriverManager