pgsql: Add pgstattuple_approx() to the pgstattuple extension.

Started by Andres Freundabout 11 years ago1 messagescomitters
Jump to latest
#1Andres Freund
andres@anarazel.de

Add pgstattuple_approx() to the pgstattuple extension.

The new function allows to estimate bloat and other table level statics
in a faster, but approximate, way. It does so by using information from
the free space map for pages marked as all visible in the visibility
map. The rest of the table is actually read and free space/bloat is
measured accurately. In many cases that allows to get bloat information
much quicker, causing less IO.

Author: Abhijit Menon-Sen
Reviewed-By: Andres Freund, Amit Kapila and Tomas Vondra
Discussion: 20140402214144.GA28681@kea.toroid.org

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/5850b20f58a594ac69f4f77b24cad94fc3bfd946

Modified Files
--------------
contrib/pgstattuple/Makefile | 4 +-
contrib/pgstattuple/pgstatapprox.c | 273 +++++++++++++++++++++++++
contrib/pgstattuple/pgstattuple--1.2--1.3.sql | 18 ++
contrib/pgstattuple/pgstattuple--1.2.sql | 79 -------
contrib/pgstattuple/pgstattuple--1.3.sql | 95 +++++++++
contrib/pgstattuple/pgstattuple.control | 2 +-
doc/src/sgml/pgstattuple.sgml | 136 +++++++++++-
7 files changed, 524 insertions(+), 83 deletions(-)

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers