pg_basebackup test coverage

Поиск
Список
Период
Сортировка
От Robert Haas
Тема pg_basebackup test coverage
Дата
Msg-id CA+TgmobeTE0Bot5AGO5CXFAHje1r0hCfWZ73j5jHEpWqVfCD5w@mail.gmail.com
обсуждение исходный текст
Ответы Re: pg_basebackup test coverage  (Noah Misch <noah@leadboat.com>)
Список pgsql-hackers
$SUBJECT is not great. The options to pg_basebackup that are not
tested by any part of the regression test suite include the
single-letter options rlzZdUwWvP as well as --no-estimate-size.

It would probably be good to fix as much of this as we can, but there
are a couple of cases I think would be particularly good to cover. One
is 'pg_basebackup -Ft -Xnone -D -', which tries to write the output as
a single tar file on standard output, injecting the backup_manifest
file into the tar file instead of writing it out separately as we
normally would. This case requires special handling in a few places
and it would be good to check that it actually works. The other is the
-z or -Z option, which produces a compressed tar file.

Now, there's nothing to prevent us from running commands like this
from the pg_basebackup tests, but it doesn't seem like we could really
check anything meaningful. Perhaps we'd notice if the command exited
non-zero or didn't produce any output, but it would be nice to verify
that the resulting backups are actually correct. The way to do that
would seem to be to extract the tar file (and decompress it first, in
the -z/-Z case) and then run pg_verifybackup on the result and check
that it passes. However, as far as I can tell there's no guarantee
that the user has 'tar' or 'gunzip' installed on their system, so I
don't see a clean way to do this. A short (but perhaps incomplete)
search didn't turn up similar precedents in the existing tests.

Any ideas?

-- 
Robert Haas
EDB: http://www.enterprisedb.com



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

Предыдущее
От: Stephen Frost
Дата:
Сообщение: Re: Change default of checkpoint_completion_target
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: On login trigger: take three