Shared lock (aka reader-writer lock) with timeouts and FIFO ordering

Category: Python - Miscellaneous

This shared lock implementation supports timeouts so that an attempt to acquire a lock occasionally times out. It also preserves FIFO ordering for threads waiting for exclusive lock and has other valuable features. Date: 26 February, 2012


Threads

Homepage: http://code.activestate.com/recipes/465156-shared-lock-aka-reader-writer-lock-with-timeouts-a/?in=lang-python

Developer: Dmitry Dvoinikov

License: Python License

Operating System: Windows

Add a Comment

all are required fields

     
What do you think of this resource?

Select Your Rate:

Votes:0

 

Related Scripts Download

ShowThread() is the only function of interest, all the others are just helper functions.

developer Developer: Francisco Charrua
license License: Freeware
operating systems Operating System: Linux, Unix, Windows


This script gives access to the Sync class.

developer Developer: code.activestate.com
license License: Freeware
operating systems Operating System: All


MQ4CPP, or "Message Queuing for C ", is an open source implementation of enterprise messaging system, also referred to as message-oriented middleware (MOM).

developer Developer: sixtyfourbit.org
license License: Artistic License, GNU General Public License (GPL)
operating systems Operating System: Windows, Linux, Mac OS, BSD, Solaris


A simple daemon that will constantly keep track the size of your inbox and when it exceeds a certain size, will send you a reminder email.

developer Developer: ajaymenon.k
license License: Freeware
operating systems Operating System: Windows


A decorator, that makes it easy to switch between the mainthread and background threads.

developer Developer: PRITAM K
license License: Freeware
operating systems Operating System: Windows


Progress bars are popular when trying to
show how much of a job has been completed.

developer Developer: Petr Zizka
license License: Python License
operating systems Operating System: Windows


The following class implements a reader-writer lock to use in the second readers-writers problem with python threads.

developer Developer: Mateusz Kobos
license License: Freeware
operating systems Operating System: Windows


An enhanced version of yaptu, with the following changes
- separated parsing from execution
- added caching of parsed templates
- added some error reporting
- added a choice of template syntaxes
- added comment syntax
- added Cheetah-style variable substitution with optional caching of the equivalent Python expression
- limited flow control to 'for' and 'if'
Reasonably small, no external dependencies,....

developer Developer: Michael Palmer
license License: Python License
operating systems Operating System: Windows


This recipe describes how to set up a simple HTTP server supporting SSL secure communications.

developer Developer: Sebastien Martini
license License: Python License
operating systems Operating System: Windows