Re: allow granting CLUSTER, REFRESH MATERIALIZED VIEW, and REINDEX

Поиск
Список
Период
Сортировка
От Jeff Davis
Тема Re: allow granting CLUSTER, REFRESH MATERIALIZED VIEW, and REINDEX
Дата
Msg-id edf8dc01333f4b3355aa91001cb26029cab1eb2e.camel@j-davis.com
обсуждение исходный текст
Ответ на Re: allow granting CLUSTER, REFRESH MATERIALIZED VIEW, and REINDEX  (Nathan Bossart <nathandbossart@gmail.com>)
Ответы Re: allow granting CLUSTER, REFRESH MATERIALIZED VIEW, and REINDEX  (Nathan Bossart <nathandbossart@gmail.com>)
Re: allow granting CLUSTER, REFRESH MATERIALIZED VIEW, and REINDEX  (Michael Paquier <michael@paquier.xyz>)
Список pgsql-hackers
On Mon, 2023-06-19 at 14:55 -0700, Nathan Bossart wrote:
> I'm hoping to commit 0002 and 0003 by the end of the week so
> that these fixes are available in 16beta2.

A few observations for the case where a user does have the MAINTAIN
privilege on a partitioned table but not the partitions:

 * they can LOCK TABLE on the partitioned table
 * ANALYZE works on the inheritance tree but not the individual
partitions
 * CLUSTER and VACUUM are useless because they skip all of the
partitions. That's consistent with the purpose of this thread -- to
avoid the locking problems trying to support those operations on
partitioned tables.
 * REINDEX TABLE applies to all indexes in all partitions, which seems
a bit inconsistent.

The only behavior I'm worried about is REINDEX. I'm not sure what we
should do about it, or if we even want to do something about it. If we
want REINDEX to fail in this case, we should be sure to check
permissions on everything up-front to avoid doing a lot of work. The
only other option I can think of is to REINDEX only those indexes
declared on the partitioned table (not the individual partitions),
which seems consistent but might be confusing to users.


Regards,
    Jeff Davis




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

Предыдущее
От: jian he
Дата:
Сообщение: Re: Do we want a hashset type?
Следующее
От: Tomas Vondra
Дата:
Сообщение: Re: Do we want a hashset type?