Re: [WIP] CREATE SUBSCRIPTION with FOR TABLES clause (table filter)

Поиск
Список
Период
Сортировка
От Evgeniy Efimkin
Тема Re: [WIP] CREATE SUBSCRIPTION with FOR TABLES clause (table filter)
Дата
Msg-id 1470811544114851@myt4-a988562a11ab.qloud-c.yandex.net
обсуждение исходный текст
Ответ на Special role for subscriptions  (Evgeniy Efimkin <efimkin@yandex-team.ru>)
Ответы Re: [WIP] CREATE SUBSCRIPTION with FOR TABLES clause (table filter)  (Andrey Borodin <x4mmm@yandex-team.ru>)
Список pgsql-hackers
Hello!

Thank you for questions!

> I've got few questions:
> 1. How will the subscription work for inherited tables? Do we need tests for that?
For subscription created with `FOR TABLE` we can't support inherit tables because subscriber don't know anything about
inherit.In new patch i remove `ONLY` for `FOR TABLE` in subscription related statements
 
> 2. ALTER PUBLICATION has ADD\DROP and SET. Should we add SET too? Or is there a reason not to do that?
Added it in new patch
> 3. Message "Must be superuser to create FOR ALL TABLES subscriptions" seems a bit strange to me. Also, this literal
isembedded into translations. I do not know how we deal with it, how do we deal for example with "måste vara
superanvändareför att skapa prenumerationer" or "для создания подписок нужно быть суперпользователем"? Where do we
insertFOR ALL TABLES?
 
I add hint `Use CREATE SUBSCRIPTION ... FOR TABLE ...`
> 4. How does default behavior differ from FOR ALL TABLES?
The same with default implementation
> 5. Can we alter subscription FOR ALL TABLES? Drop some tables out of the subscription?
For subscriptions created with `FOR ALL TABLES` (default), you can't change subscribed tables by `ALTER SUBSCRIPTION
ADD/DROP`table, you should use `ALTER SUBSCRIPTION REFRESH PUBLICATION`
 

And i don't know how do export for user created subscriptions, because now non superuser can't select subconninfo
column

03.12.2018, 09:06, "Andrey Borodin" <x4mmm@yandex-team.ru>:
> Hi, Evgeniy!
>
> Thanks for working on the feature.
>>  28 нояб. 2018 г., в 21:41, Evgeniy Efimkin <efimkin@yandex-team.ru> написал(а):
>>
>>  Hello!
>>  I wrote some tests(it's just 01_rep_changes.pl but for non superuser) and fix `DROP TABLE` from subscription. Now
oldand new tests pass.
 
>>
>>  22.11.2018, 16:23, "Evgeniy Efimkin" <efimkin@yandex-team.ru>:
>>>  Hello!
>>>  New draft attached with filtering table in subscription (ADD/DROP) and allow non-superusers use` CREATE
SUBSCRIPTION`for own tables.
 
>
> I've looked into the patch. The code looks good and coherent to nearby code.
> There are no docs, obviously, there is WiP.
>
> I've got few questions:
> 1. How will the subscription work for inherited tables? Do we need tests for that?
> 2. ALTER PUBLICATION has ADD\DROP and SET. Should we add SET too? Or is there a reason not to do that?
> 3. Message "Must be superuser to create FOR ALL TABLES subscriptions" seems a bit strange to me. Also, this literal
isembedded into translations. I do not know how we deal with it, how do we deal for example with "måste vara
superanvändareför att skapa prenumerationer" or "для создания подписок нужно быть суперпользователем"? Where do we
insertFOR ALL TABLES?
 
> 4. How does default behavior differ from FOR ALL TABLES?
> 5. Can we alter subscription FOR ALL TABLES? Drop some tables out of the subscription?
>
> Best regards, Andrey Borodin.

-------- 
Ефимкин Евгений

Вложения

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

Предыдущее
От: "Jonah H. Harris"
Дата:
Сообщение: Re: proposal: plpgsql pragma statement
Следующее
От: Robert Haas
Дата:
Сообщение: Re: [PATCH] Opclass parameters