pg_dump and concurrent DDL activity

Поиск
Список
Период
Сортировка
От Ashutosh Bapat
Тема pg_dump and concurrent DDL activity
Дата
Msg-id CAExHW5v_-FWJxn+srfQc8U3wzdZwcUWM4JMKAafuJnZHVPFAMw@mail.gmail.com
обсуждение исходный текст
Список pgsql-hackers
Hi All,
prologue of pg_dump.c says
 *  Note that pg_dump runs in a transaction-snapshot mode transaction,
 *  so it sees a consistent snapshot of the database including system
 *  catalogs. However, it relies in part on various specialized backend
 *  functions like pg_get_indexdef(), and those things tend to look at
 *  the currently committed state.  So it is possible to get 'cache
 *  lookup failed' error if someone performs DDL changes while a dump is
 *  happening. The window for this sort of thing is from the acquisition
 *  of the transaction snapshot to getSchemaData() (when pg_dump acquires
 *  AccessShareLock on every table it intends to dump). It isn't very large,
 *  but it can happen.

But this possible failure has not been documented at
https://www.postgresql.org/docs/12/app-pgdump.html. Although the
window for failure is small, it's not impossible.Should we document
this kind of failure?

-- 
Best Wishes,
Ashutosh Bapat



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

Предыдущее
От: Amit Kapila
Дата:
Сообщение: Re: Bump default wal_level to logical
Следующее
От: Tom Lane
Дата:
Сообщение: Re: text coverage for EXTRACT()