pgsql: Move materialized views' is-populated status into their pg_class

Поиск
Список
Период
Сортировка
От Tom Lane
Тема pgsql: Move materialized views' is-populated status into their pg_class
Дата
Msg-id E1UZPCM-00015F-EN@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Move materialized views' is-populated status into their pg_class entries.

Previously this state was represented by whether the view's disk file had
zero or nonzero size, which is problematic for numerous reasons, since it's
breaking a fundamental assumption about heap storage.  This was done to
allow unlogged matviews to revert to unpopulated status after a crash
despite our lack of any ability to update catalog entries post-crash.
However, this poses enough risk of future problems that it seems better to
not support unlogged matviews until we can find another way.  Accordingly,
revert that choice as well as a number of existing kluges forced by it
in favor of creating a pg_class.relispopulated flag column.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/1d6c72a55b23554cfb946527dc77f9d80044ae2c

Modified Files
--------------
doc/src/sgml/catalogs.sgml            |   14 +++++-
doc/src/sgml/func.sgml                |    9 ----
src/backend/catalog/heap.c            |   21 +----------
src/backend/catalog/system_views.sql  |    2 +-
src/backend/commands/cluster.c        |    7 +---
src/backend/commands/createas.c       |   11 +++--
src/backend/commands/matview.c        |   68 +++++++++++++++++++-------------
src/backend/commands/vacuumlazy.c     |    6 ---
src/backend/utils/adt/dbsize.c        |   27 -------------
src/backend/utils/cache/relcache.c    |   34 ++++------------
src/bin/pg_dump/pg_dump.c             |   54 +++++++++++++++++---------
src/bin/pg_dump/pg_dump.h             |    2 +-
src/include/catalog/catversion.h      |    2 +-
src/include/catalog/heap.h            |    1 -
src/include/catalog/pg_class.h        |   20 +++++----
src/include/catalog/pg_proc.h         |    2 -
src/include/commands/matview.h        |    2 +-
src/include/utils/builtins.h          |    1 -
src/include/utils/rel.h               |   11 ++++-
src/test/regress/expected/matview.out |   18 ++++----
src/test/regress/expected/rules.out   |    2 +-
src/test/regress/sql/matview.sql      |    6 +-
22 files changed, 141 insertions(+), 179 deletions(-)


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: pgsql: Back out some recent translation updates.
Следующее
От: Tom Lane
Дата:
Сообщение: pgsql: Desultory copy-editing of the 9.3 release notes.