From: | Chris Marcellino <maps(at)levelview(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-patches(at)postgresql(dot)org |
Subject: | Re: Feature: POSIX Shared memory support |
Date: | 2007-02-07 05:46:32 |
Message-ID: | 12C1D0E7-0206-4EEE-974F-DC5BD06962C2@levelview.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-patches |
Attached is a beta of the POSIX shared memory layer. It is 75% the
original sysv_shmem.c code. I'm looking for ways to refactor it down
a bit, while changing as little of the tried-and-tested code as
possible. I though I'd put it out there for comments.
Of course, unfortunately it is more complicated than the original as
it uses both sets of API. Also, I haven't tested the crash recovery
thoroughly. The POSIX code could be used Windows-style (i.e. no
crash recovery) if one ifdef'd out the SysV calls properly, if they
had such a POSIX-only platform they needed to run Postgres on.
Using both API is certainly not ideal. You mentioned,
> We've speculated on occasion about using file locking in some form
> as a
> substitute mechanism for detecting this, but that seems to just bring
> its own set of not-too-portable assumptions
What sort of file locking did you have in mind? Do you think this
might be worth me trying?
Thanks for your help,
Chris Marcellino
Attachment | Content-Type | Size |
---|---|---|
posix_shmem.c | application/octet-stream | 21.3 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Dunstan | 2007-02-07 07:27:13 | Re: Feature: POSIX Shared memory support |
Previous Message | Chris Marcellino | 2007-02-07 04:44:34 | Re: Feature: POSIX Shared memory support |