Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #65783

Re: system wide mutex

Path csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed3a.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <rosuav@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.127
X-Spam-Level *
X-Spam-Evidence '*H*': 0.75; '*S*': 0.01; 'implements': 0.09; 'cc:addr:python-list': 0.11; 'all?': 0.16; 'commonly,': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'resource,': 0.16; 'roy': 0.16; 'prevent': 0.16; 'wrote:': 0.18; 'written': 0.21; 'feb': 0.22; 'cc:addr:python.org': 0.22; 'skip': 0.24; 'mon,': 0.24; 'cc:2**0': 0.24; 'sort': 0.25; "i've": 0.25; 'nearly': 0.26; 'header:In-Reply-To:1': 0.27; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; 'usually': 0.31; 'file': 0.32; 'quite': 0.32; 'but': 0.35; 'received:google.com': 0.35; "didn't": 0.36; 'whatever': 0.38; 'resource': 0.38; 'anything': 0.39; 'most': 0.60; 'tell': 0.60; 'offer': 0.62; 'needing': 0.65; 'smith': 0.68; 'article': 0.77; 'protect': 0.79; 'advisory': 0.84; 'all!': 0.84; 'all;': 0.84; 'locked': 0.84; 'pirates': 0.84; 'subject:system': 0.84; 'to:none': 0.92
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=iDOiNwSVOGpWgkFCBiz01+S0CSjvYHOjD9nkTKq785M=; b=STfP3aRKvuUxtEmCS2dnOPPfCZNZMk9vQ0USjTEvEBR5Rv4cAxL7U9kzhSEFqOhgPi VfQSnu0bBbz0Oxf+yUjl/OpLyHIO4V6UCWugGCNpGB7EGQoedkIcuoLIweys9aJoZ7l3 qRfs6hKL1YsEEAKHrpzR153F8JYfWIrgOkRjDwZzh/fNGdL8X0ds70UsBt+Sesd1vVZd gZinGC5FKT3Uhmbl/ApQWzdtZtbTc4enAWrfsg9/hruC4VyqvzRwYuOyR1w6FK9YGyjY 8DgjK8ZTmtR746/3GLIg+gfT53B3q/mf6Q6+UPMLaJ1mfHWVxxpzU7agskSLuBah9CPg dRkw==
MIME-Version 1.0
X-Received by 10.68.178.66 with SMTP id cw2mr33376703pbc.89.1391983758412; Sun, 09 Feb 2014 14:09:18 -0800 (PST)
In-Reply-To <roy-960294.09455209022014@news.panix.com>
References <cf62da1e-45f0-4ace-924a-b3035063c71e@googlegroups.com> <mailman.6578.1391943647.18130.python-list@python.org> <roy-960294.09455209022014@news.panix.com>
Date Mon, 10 Feb 2014 09:09:18 +1100
Subject Re: system wide mutex
From Chris Angelico <rosuav@gmail.com>
Cc "python-list@python.org" <python-list@python.org>
Content-Type text/plain; charset=UTF-8
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.6603.1391983767.18130.python-list@python.org> (permalink)
Lines 27
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1391983767 news.xs4all.nl 2978 [2001:888:2000:d::a6]:47058
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:65783

Show key headers only | View raw


On Mon, Feb 10, 2014 at 1:45 AM, Roy Smith <roy@panix.com> wrote:
> In article <mailman.6578.1391943647.18130.python-list@python.org>,
>  Skip Montanaro <skip@pobox.com> wrote:
>
>> As the author of lockfile, I can tell you it only implements advisory
>> locking. All programs needing to access the locked resources must
>> cooperate.
>
> This is true of all mutexes, no?
>

Not quite all; mandatory locks actually prevent other access. But they
require support from whatever makes the resource available - most
commonly, the file system - where cooperative locking doesn't. I've
written a number of cooperative locking systems in the past (eg to
protect a network resource, when the mounted file system didn't offer
the sort of locking I needed), and they're usually the way to go when
there's anything complicated going on.

What, all mutexes?
Yes, all mutexes!
What, all?
Well.... nearly all!

-- with apologies to WS Gilbert, HMS Pinafore, and the Pirates of Penzance

ChrisA

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

system wide mutex Asaf Las <roegltd@gmail.com> - 2014-02-09 02:39 -0800
  Re: system wide mutex Asaf Las <roegltd@gmail.com> - 2014-02-09 03:00 -0800
  Re: system wide mutex Skip Montanaro <skip@pobox.com> - 2014-02-09 05:00 -0600
    Re: system wide mutex Asaf Las <roegltd@gmail.com> - 2014-02-09 03:07 -0800
    Re: system wide mutex Roy Smith <roy@panix.com> - 2014-02-09 09:45 -0500
      Re: system wide mutex Skip Montanaro <skip@pobox.com> - 2014-02-09 09:40 -0600
      Re: system wide mutex Chris Angelico <rosuav@gmail.com> - 2014-02-10 09:09 +1100
  Re: system wide mutex Marko Rauhamaa <marko@pacujo.net> - 2014-02-09 18:14 +0200
    Re: system wide mutex Asaf Las <roegltd@gmail.com> - 2014-02-09 09:39 -0800
  Re: system wide mutex Grant Edwards <invalid@invalid.invalid> - 2014-02-10 17:00 +0000
  Re: system wide mutex Miki Tebeka <miki.tebeka@gmail.com> - 2014-02-10 09:46 -0800

csiph-web