Re: Test to dump and restore objects left behind by regression
Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
From: Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
To: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Daniel Gustafsson <daniel@yesql.se>, Tom Lane <tgl@sss.pgh.pa.us>, Michael Paquier <michael@paquier.xyz>, vignesh C <vignesh21@gmail.com>, Peter Eisentraut <peter@eisentraut.org>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2025-04-03T06:38:14Z
Lists: pgsql-hackers
Attachments
- 0001-Fix-differences-in-dumped-statistics-20250403.patch (text/x-patch) patch 0001
On Wed, Apr 2, 2025 at 3:36 PM Ashutosh Bapat <ashutosh.bapat.oss@gmail.com> wrote: > > > > No commitfest entry please. Better to add an open item on the wiki > > page. > > https://wiki.postgresql.org/wiki/Open_Items > > Posted it on the thread where I have reported the bug. Hopefully, we > will commit both the bug fix and test change to enable stats together. Looks like the problem is in the test itself as pointed out by Jeff in [1]. PFA patch fixing the test and enabling statistics back. The test file is arranged as follows 1. Setup old cluster (this step also runs regression if needed) 2. create new cluster for upgrade by modifying some configuration from the old cluster. 3. disable autovacuum on old cluster 4. Run dump/restore roundtrip test which creates a destination cluster with the same configuration as the old cluster A note about variable name changes and introduction of new variables. We run step 2 between 1 and 3 so that autovacuum gets a chance to run on the old cluster and update statistics. Autovacuum run is not necessary but useful here. Before these changes all the cluster initializations were using the same variables @initdb_params and %node_params. However with these changes, we modify the variable in step 2 and then again require original values in step 4. So I have used two sets of variables prefixed with old_ and new_ for clusters created in 1st step and 2nd step respectively. 4th step uses the variables with prefix old_. I think this change eliminates confusion caused by using same variables with different values. [1] https://www.postgresql.org/message-id/5f3703fd7f27da62a8f3615218f937507f522347.camel%40j-davis.com I will watch CF CI run to see if we see difference in statistics even after this change. -- Best Wishes, Ashutosh Bapat
Commits
-
Hide expensive pg_upgrade test behind PG_TEST_EXTRA
- d185161e4739 18.0 landed
- 37fc1803cc12 19 (unreleased) landed
-
Set log_statement=none in t/002_pg_upgrade.pl
- 64fba9c61787 18.0 landed
-
002_pg_upgrade.pl: Move pg_dump test code for better stability
- 8806e4e8deb1 18.0 landed
-
002_pg_upgrade.pl: rename some variables for clarity
- abe56227b2e2 18.0 landed
-
Verify roundtrip dump/restore of regression database
- 172259afb563 18.0 landed
-
Refactor TAP test code for file comparisons into new routine in Utils.pm
- 169208092f5c 18.0 landed
-
Virtual generated columns
- 83ea6c54025b 18.0 cited
-
Put generated_stored test objects in a schema
- 894be11adfa6 18.0 cited
-
Introduce "builtin" collation provider.
- 2d819a08a1cb 17.0 cited
-
Revert "Improve compression and storage support with inheritance"
- 74563f6b9021 17.0 cited