lock free dirstate
John Arbash Meinel
john at arbash-meinel.com
Mon Sep 28 14:57:37 BST 2009
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Robert Collins wrote:
> I plan to do an experiment this week on an OSLock free dirstate - this
> should work more robustly on NFS, AFP etc. I've tagged the bugs that
> stood out as being fixed by this as 'dirstate2' in launchpad.
>
> The design I plan to use is the one that I've spoken about before:
> - write a collection of dirstate files named by hash (like we do
> in .bzr/repository)
> - have old dirstate files attempt to rm but handle them being open by
> other processes by leaving them behind
> - have a near-atomic pointer file in the root that is updated by the
> standard foo.tmp, mv foo foo.old, mv foo.tmp foo, rm foo.old code
^- Presumably you don't need to 'mv foo foo.old' on POSIX platforms?
>
> I figure this should be pretty straight forward to hook in. It will mean
> a new tree format, but if successful will allow 'bzr diff' from a commit
> editor to work and so forth.
>
> If there are any objections to this design, please speak up now!
>
> -Rob
It sounds reasonable to me.
John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkrAwNEACgkQJdeBCYSNAANfqgCgouIdDDUpEIDcYPGlatkofCke
mLwAoMDIgJwln0FGAS/vJSBpq4ISeSWd
=k4dV
-----END PGP SIGNATURE-----
More information about the bazaar
mailing list