Re: On-demand running query plans using auto_explain and signals
От | Robert Haas |
---|---|
Тема | Re: On-demand running query plans using auto_explain and signals |
Дата | |
Msg-id | CA+TgmoYax0YVp5RGpAStyfHanNbRcTWXrOzci34+dbpJTvkCvw@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: On-demand running query plans using auto_explain and signals (Pavel Stehule <pavel.stehule@gmail.com>) |
Ответы |
Re: On-demand running query plans using auto_explain and signals
|
Список | pgsql-hackers |
On Fri, Sep 18, 2015 at 6:59 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote: > I am afraid so it has not simple and nice solution - when data sender will > wait for to moment when data are received, then we have same complexity like > we use shm_mq. > > Isn't better to introduce new background worker with responsibility to clean > orphaned DSM? That won't work, or at least not easily. On Windows, the DSM is cleaned up by the operating system as soon as nobody has it mapped. Frankly, I think you guys are making this out to be way more complicated than it really is. Basically, I think the process being queried should publish a DSM via a slot it owns. The recipient is responsible for reading it and then notifying the sender. If a second process requests data before the first process reads its data, the second process can either (1) become an additional reader of the already-published data or (2) wait for the first process to finish, and then send its own inquiry. There are some problems to solve here, but they hardly seem impossible. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company
В списке pgsql-hackers по дате отправления: