unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Rob Browning <rlb@defaultvalue.org>
Cc: emacs-devel@gnu.org
Subject: Re: MAIL_USE_FLOCK and Debian.
Date: Sat, 15 Feb 2003 14:26:33 -0600	[thread overview]
Message-ID: <87znoxi93a.fsf@raven.i.defaultvalue.org> (raw)
In-Reply-To: <E18k7iI-0006zu-00@fencepost.gnu.org> (Richard Stallman's message of "Sat, 15 Feb 2003 14:11:02 -0500")

Richard Stallman <rms@gnu.org> writes:

> Would it be correct in all cases to use liblockfile whenever
> liblockfile is available?  If so, that would be pretty easy to do.
> If that is not so, can you identify the cases in which liblockfile
> is available but should not be used?  If that can't be identified,
> we are left with trying to identify the cases where it should be
> used.

If I understand the situation correctly, I'm not sure this is anything
that actually can be decided automatically.  The problem is that in
the final analysis, the policies with respect to locking may come down
to a local administrative decision.

In the limiting case, the "right policy" may not even be something you
can decide on a per-distribution basis.  For example, say that UT
Austin uses Debian (which they do).  In theory liblockfile would be
the right choice for Emacs, but hypothetically let's also imagine that
they have a heterogeneous collection of systems (RedHat, Debian,
Gentoo, etc. (and perhaps even other archs)), all sharing a giant NFS
mounted filesystem (at least in part).  Further, lets imagine that
rather than using the native packages for Emacs, they build one copy
of Emacs for all of these systems (where possible) and publish it over
NFS.  In that case, they may well know that flock (or something else)
*is* the right answer, even for the Debian systems, because they've
explicitly arranged for that to be true.  This of course assumes that
the right answer here is for all the systems to be using the same
locking strategy (see below for a counter-example).

The failure case would be for some of the systems to be using one
strategy and some of the systems to be using a different incompatible
strategy on the same shared mail spool (or shared home directories).
On Debian systems using liblockfile, NFS mounted spools are fine, but
they wouldn't be if other systems mounting the same spools weren't
using the same strategy.

Now we might just decide that in the above case, it would be
reasonable to expect the admins to just adjust the source code for
Emacs in order to respect their policies.  However, another
alternative might be for us to just make the locking policy a more
explicit choice.  We could do whatever checking we can in configure.in
to try and pick a reasonable default, but also allow a
--with-mail-locking={flock,liblockfile,...}  argument that would
insist on a particular strategy and cause configure to fail if the
request cannot be satisfied on the current system.

> It would be good to identify them at run time.

Since this is probably a "site-wide" policy issue, my initial
impression was that perhaps the locking strategy *should* be
hard-coded at compile time.  Though I guess if you were in a situation
where the Emacs binary was being shared across multiple systems
without non-shared mail spools such that the right answer was for
Emacs to use a system-specific locking strategy for the particular
system it was being launched on, rather than a common, site-wide
locking strategy, then run-time dectection would be more appropriate.

So it seems we have some tradeoffs here.  Overall, my current feeling
is that hard-coding the choice at compile time is probably going to be
the more useful choice most of the time, and although it's perhaps a
bit less flexible that run-time selection, choosing at compile-time
does make it extremely clear what's going to happen at run-time.

-- 
Rob Browning
rlb @defaultvalue.org, @linuxdevel.com, and @debian.org
Previously @cs.utexas.edu
GPG starting 2002-11-03 = 14DD 432F AE39 534D B592  F9A0 25C8 D377 8C7E 73A4

  reply	other threads:[~2003-02-15 20:26 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-15  7:02 MAIL_USE_FLOCK and Debian Rob Browning
2003-02-15 19:11 ` Richard Stallman
2003-02-15 20:26   ` Rob Browning [this message]
2003-02-17  7:20     ` Richard Stallman
2003-02-17 15:31       ` Rob Browning
2003-02-17 21:20         ` Florian Weimer
2003-02-17 21:32           ` Rob Browning
2003-02-17 21:41             ` Florian Weimer
2003-02-17 21:56           ` Alan Shutko
2003-02-17 22:20             ` Rob Browning
2003-02-18 16:03           ` Rob Browning
2003-02-18 13:59         ` Richard Stallman
2003-02-18 15:58           ` Rob Browning
2003-02-19  7:16             ` Richard Stallman
2003-02-19 17:11               ` Rob Browning
2003-02-19 18:03                 ` David Masterson
2003-02-20 18:21                 ` Richard Stallman
2003-02-20 19:22                   ` Rob Browning
2003-02-21 21:44                     ` Richard Stallman
2003-02-24  2:58                       ` Rob Browning
2003-02-28  8:14                       ` Michael Sperber [Mr. Preprocessor]
2003-03-01 21:44                         ` Richard Stallman
2003-03-02 10:06                           ` Michael Sperber [Mr. Preprocessor]
2003-03-03 18:58                             ` Richard Stallman
2003-03-04  8:30                               ` Michael Sperber [Mr. Preprocessor]
2003-03-05 20:46                                 ` Richard Stallman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87znoxi93a.fsf@raven.i.defaultvalue.org \
    --to=rlb@defaultvalue.org \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).