> i solved this problem with poem access on my site by
> creating new read and write functions that "lock" the
> file while it's being read from or written to.
> the lock is just a temporary file that is removed as
> soon as the read or write is finished. the lock exists
> only as long as it takes to grab the data out of the
> file or write to the file ... so the lock does not
> exists the whole time the script is running, just for
> about a fraction of a second, if that.
> read locks are time stamped so there may be multiples
> of them, this is because a read lock only prevents
> writing, not reading. a write lock is just a single
> file that prevents other processes from writing to or
> reading from the file.
>
> the read and write functions recheck for the lock
> file's existence about every 100th of a second. the
> read function only checks for a write lock while the
> write function checks for a read or write lock.
>
> i'd share the functions with you, but i wrote them
> in perl. should be very easy to do in rebol.
[Thanks Erin for answering.
I think the solution you propose here is the one I presented when
initiating this thread.
It's a -relative- safe one (see thread for discussion about it) but
will give poor performences when 40 to 80 PC's you want to dump their data
together ...
Thanks anyway ;-)
Best Regards,
chr==
]
> cheerfulness,
>
> -----EAT
>
>
--
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the
subject, without the quotes.
[REBOL] Re: Concurrent access to data file
CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN Tue, 20 Feb 2001 01:59:37 -0800
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent ... Gabriele Santilli
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent ... Michal Kracik
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent ... Brett Handley
- [REBOL] Re: Concurrent ... Andrew Martin
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent ... Andrew Martin
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
- [REBOL] Re: Concurrent acces... CRS - Psy Sel/SPO, COUSSEMENT Christophe, CPN
