Re: introduce dynamic shared memory registry
От | Andrei Lepikhov |
---|---|
Тема | Re: introduce dynamic shared memory registry |
Дата | |
Msg-id | 3dcea2e9-c46d-4e4f-8371-9526d1aebc83@postgrespro.ru обсуждение исходный текст |
Ответ на | Re: introduce dynamic shared memory registry (Andrei Lepikhov <a.lepikhov@postgrespro.ru>) |
Ответы |
Re: introduce dynamic shared memory registry
Re: introduce dynamic shared memory registry Re: introduce dynamic shared memory registry |
Список | pgsql-hackers |
On 18/12/2023 13:39, Andrei Lepikhov wrote: > On 5/12/2023 10:46, Nathan Bossart wrote: >> I don't presently have any concrete plans to use this for anything, but I >> thought it might be useful for extensions for caching, etc. and wanted to >> see whether there was any interest in the feature. > > I am delighted that you commenced this thread. > Designing extensions, every time I feel pain introducing one shared > value or some global stat, the extension must be required to be loadable > on startup only. It reduces the flexibility of even very lightweight > extensions, which look harmful to use in a cloud. After looking into the code, I have some comments: 1. The code looks good; I didn't find possible mishaps. Some proposed changes are in the attachment. 2. I think a separate file for this feature looks too expensive. According to the gist of that code, it is a part of the DSA module. 3. The dsm_registry_init_or_attach routine allocates a DSM segment. Why not create dsa_area for a requestor and return it? -- regards, Andrei Lepikhov Postgres Professional
Вложения
В списке pgsql-hackers по дате отправления: