Progress report of CREATE INDEX for nested partitioned tables

Поиск
Список
Период
Сортировка
От Ilya Gladyshev
Тема Progress report of CREATE INDEX for nested partitioned tables
Дата
Msg-id a15f904a70924ffa4ca25c3c744cff31e0e6e143.camel@gmail.com
обсуждение исходный текст
Ответы Re: Progress report of CREATE INDEX for nested partitioned tables  (Justin Pryzby <pryzby@telsasoft.com>)
Список pgsql-hackers
Hi,

I have noticed that progress reporting for CREATE INDEX of partitioned
tables seems to be working poorly for nested partitioned tables. In
particular, it overwrites total and done partitions count when it
recurses down to child partitioned tables and it only reports top-level
partitions. So it's not hard to see something like this during CREATE
INDEX now:

postgres=# select partitions_total, partitions_done from
pg_stat_progress_create_index ;
 partitions_total | partitions_done 
------------------+-----------------
                1 |               2
(1 row)


I changed current behaviour to report the total number of partitions in
the inheritance tree and fixed recursion in the attached patch. I used
a static variable to keep the counter to avoid ABI breakage of
DefineIndex, so that we could backpatch this to previous versions.

Thanks,
Ilya Gladyshev

Вложения

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

Предыдущее
От: "Drouvot, Bertrand"
Дата:
Сообщение: Re: Minimal logical decoding on standbys
Следующее
От: "Drouvot, Bertrand"
Дата:
Сообщение: Re: Split index and table statistics into different types of stats