Re: "out of relcache_callback_list slots" after multiple calls to pg_logical_slot_get_binary_changes

Поиск
Список
Период
Сортировка
От Kyotaro Horiguchi
Тема Re: "out of relcache_callback_list slots" after multiple calls to pg_logical_slot_get_binary_changes
Дата
Msg-id 20230222.100303.2154543169830264615.horikyota.ntt@gmail.com
обсуждение исходный текст
Ответ на RE: "out of relcache_callback_list slots" after multiple calls to pg_logical_slot_get_binary_changes  ("shiy.fnst@fujitsu.com" <shiy.fnst@fujitsu.com>)
Ответы Re: "out of relcache_callback_list slots" after multiple calls to pg_logical_slot_get_binary_changes  (Peter Smith <smithpb2250@gmail.com>)
Список pgsql-hackers
At Tue, 21 Feb 2023 10:31:29 +0000, "shiy.fnst@fujitsu.com" <shiy.fnst@fujitsu.com> wrote in 
> Thanks for your reply. I agree that's expensive. Attach a new patch which adds a
> static boolean to avoid duplicate registration.

Thank you for the patch.  It is exactly what I had in my mind. But now
that I've had a chance to mull it over, I came to think it might be
better to register the callbacks at one place. I'm thinking we could
create a new function called register_callbacks() or something and
move all the calls to CacheRegisterSyscacheCallback() into that. What
do you think about that refactoring?

I guess you could say that that refactoring somewhat weakens the
connection or dependency between init_rel_sync_cache and
rel_sync_cache_relation_cb, but anyway the callback works even if
RelationSyncCache is not around.

regards.

-- 
Kyotaro Horiguchi
NTT Open Source Software Center



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

Предыдущее
От: Peter Smith
Дата:
Сообщение: Re: Time delayed LR (WAS Re: logical replication restrictions)
Следующее
От: Peter Smith
Дата:
Сообщение: Re: "out of relcache_callback_list slots" after multiple calls to pg_logical_slot_get_binary_changes