bedouglas at earthlink.net
Sun Mar 1 19:00:54 CET 2009
Except in my situation.. the client has no knowledge of the filenaming
situation, and i might have 1000s of files... think of the FIFO, first in,
first out.. so i'm loking for a fast solution that would allow me to create
groups of say, 500 files, that get batched and processed by the client
so in this situation, the client needs to access the files, group the files,
copy/move the files, process the files...
rather than "lock" the dir for the entire process listed above, the app
could lock the dir/files for the initial access/copy/move process.. and then
release, allowing other client processes to more quickly access the files..
but i'm wondering if there's a faster approach...
From: python-list-bounces+bedouglas=earthlink.net at python.org
[mailto:python-list-bounces+bedouglas=earthlink.net at python.org]On Behalf
Of Gabriel Genellina
Sent: Sunday, March 01, 2009 9:50 AM
To: python-list at python.org
Subject: Re: file locking...
En Sun, 01 Mar 2009 15:39:56 -0200, bruce <bedouglas at earthlink.net>
> the issue that i'm looking at is analogous to a FIFO, where i have lots
> files being shoved in a dir from different processes.. on the other end,
> want to allow mutiple client processes to access unique groups of these
> files as fast as possible.. access being fetch/gather/process/delete the
> files. each file is only handled by a single client process.
I still fail to see why do you need any locking. Could you provide a
Suppose I have 26 processes, each one handles files starting with a
certain letter. This example fits your description perfectly, and no
locking is needed at all.
More information about the Python-list