Kevin Van <kevin...@shift.com> writes:
> This patch adds a new function that allows callers to receive binary jsonb.
> This change was proposed in the discussion here:
> https://www.postgresql.org/message-id/CAOsiKEL7%2BKkV0C_hAJWxqwTg%2BPYVfiGPQ0yjFww7ECtqwBjb%2BQ%40mail.gmail.com
> and the primary motivation is to reduce database load by skipping jsonb to
> string conversion (with the expectation that the application can parse
> binary jsonb).

I dunno, I do not think it's a great idea to expose jsonb's internal
format to the world.  We intentionally did not do that when the type
was first defined --- that's why its binary I/O format isn't already
like this --- and I don't see that the tradeoffs have changed since then.
The format is complex, and specific to Postgres' needs, and we might wish
to change it in future.

                        regards, tom lane

Reply via email to