Re: pgsql: Fix "base" snapshot handling in logical decoding
Arseny Sher <a.sher@postgrespro.ru>
From: Arseny Sher <a.sher@postgrespro.ru>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Alvaro Herrera <alvherre@2ndquadrant.com>,
pgsql-hackers@lists.postgresql.org, 2q-andrew@alvin.alvh.no-ip.org
Date: 2018-06-30T15:00:21Z
Lists: pgsql-hackers
Attachments
- less_agressive_vacuum_in_oldest_xmin_test.patch (text/x-diff) patch
Tom Lane <tgl@sss.pgh.pa.us> writes:
> Alvaro Herrera <alvherre@2ndquadrant.com> writes:
>>> On 2018-Jun-28, Tom Lane wrote:
>>>> According to buildfarm member friarbird, and as confirmed here,
>>>> the contrib/test_decoding/specs/oldest_xmin.spec test added by this
>>>> commit fails under CLOBBER_CACHE_ALWAYS.
>
>> I suppose 60 seconds (isolationtester's default timeout) is just not
>> enough time for those machines. We could increase it to 180 seconds and
>> see if that's enough to make them pass ...
>
> What I want to know is why this test is doing a database-wide VACUUM FULL
> in the first place. If that isn't profligate wastage of testing cycles,
> why not?
>
> regards, tom lane
Oh, that's my fault. I think just VACUUM pg_attribute is enough there --
it takes 42ms on my laptop with CLOBBER_CACHE_ALWAYS ('vacuum full'
occupies 1 minute), patch is attached. The test is still steadily fails
without the main patch.
There is also one thing that puzzles me as I don't know much about
vacuum internals. If I do plain VACUUM of pg_attribute in the test, it
shouts "catalog is missing 1 attribute(s) for relid" error (which is
quite expected), while with 'VACUUM FULL pg_attribute' the tuple is
silently (and wrongly, with dropped column missing) decoded. Moreover,
if I perform the test manually, and do 'VACUUM FULL;', sometimes test
becomes useless -- that is, tuple is successfully decoded with all three
columns, as though VACUUM was not actually executed. All this is without
the main patch, of course. I think I will look into this soon.
--
Arseny Sher
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company
Commits
-
Reduce cost of test_decoding's new oldest_xmin test
- 7acbb481c808 10.5 landed
- 301b2a1aad77 9.6.10 landed
- eedbbff504e4 9.5.14 landed
- aba2184bed64 11.0 landed
- 8d1c1ca70b01 12.0 landed
-
Fix "base" snapshot handling in logical decoding
- f49a80c481f7 11.0 cited