From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Xiaoran Wang <fanfuxiaoran(at)gmail(dot)com> |
Cc: | pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: [patch] Imporve pqmq |
Date: | 2024-08-08 19:24:11 |
Message-ID: | CA+TgmoY=qp7gqZ9QXtgccX195XHW8Y6u6v80OU6xyFhpCfsPZg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Aug 7, 2024 at 11:24 PM Xiaoran Wang <fanfuxiaoran(at)gmail(dot)com> wrote:
> When I use the 'pqmq' recently, I found some issues, just fix them.
>
> Allow the param 'dsm_segment *seg' to be NULL in function
> 'pq_redirect_to_shm_mq'. As sometimes the shm_mq is created
> in shared memory instead of DSM.
Under what circumstances does this happen?
> Add function 'pq_leave_shm_mq' to allow the process to go
> back to the previous pq environment.
In the code as it currently exists, a parallel worker never has a
connected client, and it talks to a shm_mq instead. So there's no need
for this. If a backend needs to communicate with both a connected
client and also a shm_mq, it probably should not use pqmq but rather
decide explicitly which messages should be sent to the client and
which to the shm_mq. Otherwise, it seems hard to avoid possible loss
of protocol sync.
--
Robert Haas
EDB: http://www.enterprisedb.com
From | Date | Subject | |
---|---|---|---|
Next Message | Jeff Davis | 2024-08-08 19:24:28 | [18] Fix a few issues with the collation cache |
Previous Message | Robert Haas | 2024-08-08 19:18:36 | Re: Don't overwrite scan key in systable_beginscan() |