> On Sep 9, 2026, at 18:33, Hayato Kuroda (Fujitsu) <[email protected]> 
> wrote:
> 
> Dear Fujii-san, Jacob,
> 
> Thanks for giving feedbacks. I'm confusing and let me confirm few points.
> The situation might be different before and after the PG19.
> 
> For PG17 and 18, FOR ALL TABLES publications for publisher databases,
> it meant superuser is required for the connection. IIUC superuser can bypass 
> all
> permission checks thus it might be OK not to check these points.
> (We may have to check it though).
> As for the PG19 and HEAD, we allowed to re-use existing publications [1], it
> effectively allowed to use non-superuser for connecting to the publisher.
> However it meant additional permission checks might be needed like Jacob 
> pointed
> out.
> 
> In this thread I do not want to broaden for other points and focus on the 
> added
> GUC, thought? In other threads we can improve --check option more.
> 
> Based on that, permission check is actually needed for PG19/HEAD same check
> Fujii-san pointed out. For PG18/17, we may not have to take care the usage of
> current_setting() but same code is used for better understanding. Attached 
> patch
> set does accordingly. v5-0001 also has a test for the case just in case, but 
> not
> sure it should be pushed.
> 
> [1]: 
> https://github.com/postgres/postgres/commit/85ddcc2f4cdef490276d151c80459e287bceb782
> 
> Best regards,
> Hayato Kuroda
> FUJITSU LIMITED
> 
> <v5-PG17-0001-pg_createsubscriber-ensure-output_plugin_lib.txt><v5-PG18-0001-pg_createsubscriber-ensure-output_plugin_lib.txt><v5-PG18-0002-free-allocated-memory-for-max_slot_wal_keep_.txt><v5-0001-pg_createsubscriber-ensure-output_plugin_librarie.patch><v5-0002-free-allocated-memory-for-max_slot_wal_keep_size.patch>

I have nit comment on 0001:
```
+/*
+ * Check per-database settings on the publisher
+ */
+static void
+check_publisher_per_database(const struct LogicalRepInfo *dbinfo)
```

I find the header comment slightly misleading. Although output_plugin_libraries 
is checked separately for each database connection, its effective value may 
come from database, role, or connection-level settings. So, maybe rephrase it 
as: Check effective settings for each publisher database.

Best regards,
--
Chao Li (Evan)
HighGo Software Co., Ltd.
https://www.highgo.com/






Reply via email to