Fujii Masao wrote:
> On Tue, Sep 9, 2008 at 10:55 PM, Markus Wanner <markus@bluegap.ch> wrote:
>> Hi,
>>
>> ITAGAKI Takahiro wrote:
>>> Signals and locking, borrewed from Postgres-R, are now studied
>>> for the purpose in the log shipping,
>> Cool. Let me know if you have any questions WRT this imessages stuff.
>
> If you're sure it's all right, I have a trivial question.
Well, I know it works for me and I think it could work for you, too.
That's all I'm saying.
> Which signal should we use for the notification to the backend from
> WAL sender? The notable signals are already used.
I'm using SIGUSR1, see src/backend/storage/ipc/imsg.c from Postgres-R,
line 232. That isn't is use for backends or the postmaster, AFAIK.
> Or, since a backend don't need to wait on select() unlike WAL sender,
> ISTM that it's not so inconvenient to use a semaphore for that notification.
They probably could, but not the WAL sender.
What's the benefit of semaphores? It seems pretty ugly to set up a
semaphore, lock that on the WAL sender, then claim it on the backend to
wait for it, and then release it on the WAL sender to notify the backend.
If all you want to do is to signal the backend, why not use signals ;-)
But maybe I'm missing something?
Regards
Markus Wanner
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
No comments:
Post a Comment