Adding a TAP test checking data consistency on standby withminRecoveryPoint

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Adding a TAP test checking data consistency on standby withminRecoveryPoint
Дата
Msg-id 20181108044525.GA17482@paquier.xyz
обсуждение исходный текст
Ответы Re: Adding a TAP test checking data consistency on standby with minRecoveryPoint  (Andrew Gierth <andrew@tao11.riddles.org.uk>)
Список pgsql-hackers
Hi all,

While working on a fix for c186ba13 which fixes the way minRecoveryPoint
is updated for other processes than the startup process, I was
struggling about being able to get that into a reproducible test case.

I have been thinking what Andrew Gierth has mentioned yesterday, and
roughly designed a test case mentioned here which is able to see the
problem:
https://www.postgresql.org/message-id/20181107044915.GF1677@paquier.xyz

I have also been trying to shape that into a TAP test which can be added
into the in-core recovery test suite, and it happens that the part which
scans if all the pages of a relation are not newer than what
minRecoveryPoint is set to in the control file can be easily calculated
by using pageinspect and pg_control_recovery() with a simple SQL query.
So, digging into it, I have been able to get a reproducible TAP test
case which is in the patch attached.

On HEAD, if you revert c186ba13 and then trigger the test the
inconsistency shows up immediately.  Keeping the fix makes the test
pass.

This test suite will make sure that we don't break again how
minRecoveryPoint is handled across multiple processes, so I think that
it would be a good addition for HEAD and the future.

Thoughts?
--
Michael

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Amit Langote
Дата:
Сообщение: Re: move PartitionBoundInfo creation code
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: file cloning in pg_upgrade and CREATE DATABASE