Re: HEADS UP: Win32/OS2/BeOS native ports

From: "Igor Kovalenko" <Igor(dot)Kovalenko(at)motorola(dot)com>
To: "Matthew Kirkwood" <matthew(at)hairy(dot)beasts(dot)org>
Cc: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Marc G(dot) Fournier" <scrappy(at)hub(dot)org>, "mlw" <markw(at)mohawksoft(dot)com>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: HEADS UP: Win32/OS2/BeOS native ports
Date: 2002-05-09 02:53:15
Message-ID: 016a01c1f704$ab9abfe0$22c30191@comm.mot.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Ahh... you want a named semaphore... There is such a thing in POSIX but it
is only portable if their names begin with "/" (which tells OS to put it
where appropriate). I believe without leading slash they end up in current
directory, but we can't rely on that... too bad. Glad UDS it is getting
supported on my platform, lol ;)

This will however leave QNX4 in the dust, if anyone cares. And most likely
BeOS, MP/X and half dozen other platforms. Which prompts me to think if it
would not be better to come up with a platform independent 'namespace sync'
mechanism. Can't we use fcntl()-based lock for that purpose? That's what
apache is doing apparently (one of variants).

-- igor

> On Wed, 8 May 2002, Igor Kovalenko wrote:
>
> > Can you be more specific? What required syntax? I was talking about
> > named pipe vs UDS socket...
>
> Sorry, I meant semantics.
>
> A pipe can have multiple readers and multiple writers. This is
> no use for us.
>
> A listening SOCK_STREAM Unix domain socket can have no readers or
> writers, but only one listener (well, except that other processes
> can inherit or be passed the socket). You have to connect() (and
> the server must accept()) before read and write do anything. But
> we have no use for that here. It's just an exclusive-only mutex
> whose namespace is the filesystem.
>
> It really is like a TCP socket, except that the address namespace
> is the filesystem, and thus it's not available remotely.
>
> Think of it as a TCP socket without the "which address and port
> do I use, and how do I keep it secure" issues.
>
> Matthew.
>

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Christopher Kings-Lynne 2002-05-09 03:16:52 7.2 html docs
Previous Message Rod Taylor 2002-05-09 02:07:02 Regression tests and NOTICE statements