postgres/contrib
Alvaro Herrera 7acbb481c8 Reduce cost of test_decoding's new oldest_xmin test
Change a whole-database VACUUM into doing just pg_attribute, which is
the portion that verifies what we want it to do.  The original
formulation wastes a lot of CPU time, which leads the test to fail when
runtime exceeds isolationtester timeout when it's super-slow, such as
under CLOBBER_CACHE_ALWAYS.  Per buildfarm member friarbird.

It turns out that the previous shape of the test doesn't always detect
the condition it is supposed to detect (on unpatched reorderbuffer
code): the reason is that there is a good chance of encountering a
xl_running_xacts record (logged every 15 seconds) before the checkpoint
-- and because we advance the xmin when we receive that WAL record, and
we *don't* advance the xmin twice consecutively without receiving a
client message in between, that means the xmin is not advanced enough
for the tuple to be pruned from pg_attribute by VACUUM.  So the test
would spuriously pass.

The reason this test deficiency wasn't detected earlier is that HOT
pruning removes the tuple anyway, even if vacuum leaves it in place, so
the test correctly fails (detecting the coding mistake), but for the
wrong reason.

To fix this mess, run the s0_get_changes step twice before vacuum
instead of once: this seems to cause the xmin to be advanced reliably,
wreaking havoc with more certainty.

Author: Arseny Sher
Discussion: https://postgr.es/m/87h8lkuxoa.fsf@ars-thinkpad
2018-07-05 16:58:30 -04:00
..
adminpack adminpack: Revoke EXECUTE on pg_logfile_rotate() 2018-05-07 10:10:41 -04:00
amcheck Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
auth_delay Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
auto_explain Allow auto_explain.log_min_duration to go up to INT_MAX. 2018-02-23 14:39:18 -05:00
bloom Fix errors in contrib/bloom index build. 2018-03-22 13:13:58 -04:00
btree_gin Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
btree_gist Fix assorted issues in convert_to_scalar(). 2018-03-03 20:31:35 -05:00
chkpass Further cleanup from the strong-random patch. 2016-12-12 11:55:32 +02:00
citext Optimize joins when the inner relation can be proven unique. 2017-04-07 22:20:13 -04:00
cube Remove wrongly backpatched piece of code in cube.c 2018-04-10 14:58:46 +03:00
dblink Remove uses of "slave" in replication contexts 2017-08-10 22:55:41 -04:00
dict_int Update copyright via script for 2017 2017-01-03 13:48:53 -05:00
dict_xsyn Update copyright via script for 2017 2017-01-03 13:48:53 -05:00
earthdistance Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
file_fdw Even if some partitions are foreign, allow tuple routing. 2017-09-07 10:59:28 -04:00
fuzzystrmatch Phase 2 of pgindent updates. 2017-06-21 15:19:25 -04:00
hstore Avoid formally-undefined use of memcpy() in hstoreUniquePairs(). 2017-11-25 14:42:25 -05:00
hstore_plperl Fix contrib/hstore_plperl to look through scalar refs. 2018-06-18 15:55:06 -04:00
hstore_plpython Drop support for Python 2.3 2017-02-21 09:49:22 -05:00
intagg Schema-qualify some references to regprocedure. 2016-06-10 10:41:58 -04:00
intarray Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
isn Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
lo Phase 2 of pgindent updates. 2017-06-21 15:19:25 -04:00
ltree Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
ltree_plpython Code review for avoidance of direct cross-module links. 2017-02-02 11:21:16 -05:00
oid2name Empty search_path in Autovacuum and non-psql/pgbench clients. 2018-02-26 07:39:47 -08:00
pageinspect pageinspect: Fix use of wrong memory context by hash_page_items. 2018-01-26 09:59:14 -05:00
passwordcheck Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
pg_buffercache Phase 2 of pgindent updates. 2017-06-21 15:19:25 -04:00
pg_freespacemap Default monitoring roles 2017-03-30 14:18:53 -04:00
pg_prewarm Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
pg_standby Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
pg_stat_statements Code review for NextValueExpr expression node type. 2017-07-14 15:25:43 -04:00
pg_trgm Rework word_similarity documentation, make it close to actual algorithm. 2018-03-21 14:37:18 +03:00
pg_visibility Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
pgcrypto Rename base64 routines to avoid conflict with Solaris built-in functions. 2018-02-28 18:33:45 -05:00
pgrowlocks Teach pgrowlocks to check relkind before scanning 2017-06-21 23:19:13 -04:00
pgstattuple pgstatindex: Insert some casts to prevent overflow. 2017-08-10 11:48:42 -04:00
postgres_fdw Change more places to be less trusting of RestrictInfo.is_pushed_down. 2018-04-20 15:19:16 -04:00
seg Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
sepgsql Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
spi Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
sslinfo Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
start-scripts Provide modern examples of how to auto-start Postgres on macOS. 2017-11-17 12:47:11 -05:00
tablefunc Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
tcn Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
test_decoding Reduce cost of test_decoding's new oldest_xmin test 2018-07-05 16:58:30 -04:00
tsm_system_rows Update copyright via script for 2017 2017-01-03 13:48:53 -05:00
tsm_system_time Update copyright via script for 2017 2017-01-03 13:48:53 -05:00
unaccent Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
uuid-ossp Phase 2 of pgindent updates. 2017-06-21 15:19:25 -04:00
vacuumlo Empty search_path in Autovacuum and non-psql/pgbench clients. 2018-02-26 07:39:47 -08:00
xml2 Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
contrib-global.mk Respect TEMP_CONFIG when pg_regress_check and friends are called 2016-02-27 12:28:21 -05:00
Makefile Add amcheck extension to contrib. 2017-03-09 16:33:02 -08:00
README Rename 'gmake' to 'make' in docs and recommended commands 2014-02-12 17:29:19 -05:00

The PostgreSQL contrib tree
---------------------------

This subtree contains porting tools, analysis utilities, and plug-in
features that are not part of the core PostgreSQL system, mainly
because they address a limited audience or are too experimental to be
part of the main source tree.  This does not preclude their
usefulness.

User documentation for each module appears in the main SGML
documentation.

When building from the source distribution, these modules are not
built automatically, unless you build the "world" target.  You can
also build and install them all by running "make all" and "make
install" in this directory; or to build and install just one selected
module, do the same in that module's subdirectory.

Some directories supply new user-defined functions, operators, or
types.  To make use of one of these modules, after you have installed
the code you need to register the new SQL objects in the database
system by executing a CREATE EXTENSION command.  In a fresh database,
you can simply do

    CREATE EXTENSION module_name;

See the PostgreSQL documentation for more information about this
procedure.