Repair unstable regression test.
authorTom Lane
Tue, 9 Jun 2020 05:17:59 +0000 (01:17 -0400)
committerTom Lane
Tue, 9 Jun 2020 05:18:34 +0000 (01:18 -0400)
Commit 0c882e52a tried to force table atest12 to have more-accurate-
than-default statistics; but transiently setting default_statistics_target
isn't enough for that, because autovacuum could come along and overwrite
the stats later.  This evidently explains some intermittent buildfarm
failures we've seen since then.  Repair by disabling autovac on this table.

Thanks to David Rowley for correctly diagnosing the cause.

Discussion: https://postgr.es/m/CA+hUKG+OUkQSOUTg=qo=S=fWa_tbm99i7rB7mfbHz1SYm4v-jQ@mail.gmail.com

src/test/regress/expected/privileges.out
src/test/regress/sql/privileges.sql

index 7caf0c9b6b93ff5301b9ab52acd211ac2c02c071..3ec22c20ea1b29da61706b6dc401c6d32358032e 100644 (file)
@@ -191,7 +191,8 @@ CREATE TABLE atest12 as
   SELECT x AS a, 10001 - x AS b FROM generate_series(1,10000) x;
 CREATE INDEX ON atest12 (a);
 CREATE INDEX ON atest12 (abs(a));
--- results below depend on having quite accurate stats for atest12
+-- results below depend on having quite accurate stats for atest12, so...
+ALTER TABLE atest12 SET (autovacuum_enabled = off);
 SET default_statistics_target = 10000;
 VACUUM ANALYZE atest12;
 RESET default_statistics_target;
index 0ab5245b1ebf99d7f5e1cb0f1e07933e99b0adfa..3550f61587a84800b1f5e97a517b800401a8e845 100644 (file)
@@ -136,7 +136,8 @@ CREATE TABLE atest12 as
   SELECT x AS a, 10001 - x AS b FROM generate_series(1,10000) x;
 CREATE INDEX ON atest12 (a);
 CREATE INDEX ON atest12 (abs(a));
--- results below depend on having quite accurate stats for atest12
+-- results below depend on having quite accurate stats for atest12, so...
+ALTER TABLE atest12 SET (autovacuum_enabled = off);
 SET default_statistics_target = 10000;
 VACUUM ANALYZE atest12;
 RESET default_statistics_target;