Re: jsonb format is pessimal for toast compression

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Gavin Flower <GavinFlower(at)archidevsys(dot)co(dot)nz>, Peter Geoghegan <pg(at)heroku(dot)com>, Bruce Momjian <bruce(at)momjian(dot)us>, Stephen Frost <sfrost(at)snowman(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, Kevin Grittner <kgrittn(at)ymail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>, Larry White <ljw1001(at)gmail(dot)com>
Subject: Re: jsonb format is pessimal for toast compression
Date: 2014-08-15 00:06:10
Message-ID: 53ED4EF2.3060304@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 08/14/2014 04:47 PM, Josh Berkus wrote:
> thetype | colsize_distribution
> ---------+----------------------------
> json | {1777,1803,1890,1940,4424}
> jsonb | {5902,5926,5978,6002,6208}

Just realized my query was counting the whole row size instead of just
the column size. Here's just the JSON column:

Before changing to to INT_MAX:

thetype | colsize_distribution
---------+----------------------------
json | {1741,1767,1854,1904,2292}
jsonb | {3551,5866,5910,5958,6168}

After:

thetype | colsize_distribution
---------+----------------------------
json | {1741,1767,1854,1904,2292}
jsonb | {3515,3543,3636,3690,4038}

So that did improve things, just not as much as we'd like.

--
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Craig Ringer 2014-08-15 00:45:42 Re: Reporting the commit LSN at commit time
Previous Message Josh Berkus 2014-08-14 23:47:32 Re: jsonb format is pessimal for toast compression