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

From: Andrey Borodin <x4mmm(at)yandex-team(dot)ru>
To: Evgeniy Efimkin <efimkin(at)yandex-team(dot)ru>
Cc: Stephen Frost <sfrost(at)snowman(dot)net>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>, Дмитрий Сарафанников <dsarafan(at)yandex-team(dot)ru>, Владимир Бородин <root(at)simply(dot)name>
Subject: Re: [WIP] CREATE SUBSCRIPTION with FOR TABLES clause (table filter)
Date: 2018-12-03 06:06:05
Message-ID: 589F5EB5-77F8-47ED-9E2B-214B9D4CAB16@yandex-team.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi, Evgeniy!

Thanks for working on the feature.
> 28 нояб. 2018 г., в 21:41, Evgeniy Efimkin <efimkin(at)yandex-team(dot)ru> написал(а):
>
> Hello!
> I wrote some tests(it's just 01_rep_changes.pl but for non superuser) and fix `DROP TABLE` from subscription. Now old and new tests pass.
>
> 22.11.2018, 16:23, "Evgeniy Efimkin" <efimkin(at)yandex-team(dot)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 is embedded into translations. I do not know how we deal with it, how do we deal for example with "måste vara superanvändare för att skapa prenumerationer" or "для создания подписок нужно быть суперпользователем"? Where do we insert FOR 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.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2018-12-03 06:29:29 Re: WIP: Avoid creation of the free space map for small tables
Previous Message Chris Travers 2018-12-03 05:56:59 Re: Proposal for Signal Detection Refactoring