file locking primitive
david at gorisek.com
Sat Jan 3 20:42:32 UTC 2004
sorry for the misunderstanding. The point I was trying to make is that
file locking behavior is different between OSs.
For example in VisualWorks the file locking primitive does not behave
consistently between Linux and Windows version. Therefore OmniBase for
VisualWorks (and for Smalltalk/X) keeps track of locks set on a file to
prevent setting a lock twice (internally using a Dictionary).
So, if Squeak had a file locking primitive it would be nice if it
behaved the same across various OSs.
From: squeak-dev-bounces at lists.squeakfoundation.org
[mailto:squeak-dev-bounces at lists.squeakfoundation.org] On Behalf Of
Sent: 3. januar 2004 21:12
To: The general-purpose Squeak developers list
Subject: Re: file locking primitive
Hmm... Andrew seemed to be under the impression that the locking
currently didn't work at all on *nix (in the latest code you've given
us) and that adding a primitive was the correct action. If this already
works, we should be doing something else, or you're already doing it
then I would definitely like to know about it... :)
We do need to run the server on *nix, so what do you recommend?
David Gorisek wrote:
> Regarding file locking primitives, there is also another issue that
> has to be taken into account.
> On Unix when the same process locks the same file region twice, the
> second call will succeed.
> On Windows the second call will fail, becuase the file region is
> already locked.
> For true interoperability the file locking behavior should be the same
> across various OSs.
> OmniBase expects that file locking behavior is the same as on Windows.
> Therefore for Unix systems OmniBase currently implements its own
> internal file locking table so that locking behavior of the
> ODBFileStream is the same as on Windows.
> David Gorisek
julian at beta4.com
Beta4 Productions (http://www.beta4.com)
More information about the Squeak-dev