pgsql: test_custom_stats: Stabilize test for counters
test_custom_stats: Stabilize test for counters
After 44539786b82, variable-sized stats updates are batched in one
backend. A later safe_psql() can check the counters before that backend
has finished flushing its pending stats during shutdown, so force a
flush before checking them.
This is only needed before this report check because
test_custom_stats_var_update() uses pgstat_prep_pending_entry(), leaving
counter updates as backend-local pending stats.
Per buildfarm member mamba. This could be reproduced locally by slowing
down pgstat_shutdown_hook().
Reported-by: Tom Lane <tgl@sss.pgh.pa.us>
Author: Sami Imseih <samimseih.pg@gmail.com>
Discussion: /messages/by-id/193326.1792282194@sss.pgh.pa.us
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/8afc886831bc629e524cc7185b2fdc0092aecc93
Modified Files
--------------
src/test/modules/test_custom_stats/t/001_custom_stats.pl | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)