[tahoe-dev] source control in LAFS (was: split brain/partition tolerance? how handled in tahoe -- docs?)
Zooko Wilcox-O'Hearn
zooko at zooko.com
Wed Aug 8 23:19:33 UTC 2012
There are several ways to put your revision control repository into
LAFS. The obvious one is mount LAFS with FUSE or pyfilesystem and
point your revision control tool at the mount point. That will
probably work with every modern revision control tool. If anyone has
tried that, I would like to hear how it performed.
There are also hacks for specific revision control tools:
• mercurial: https://tahoe-lafs.org/pipermail/tahoe-dev/2010-June/004559.html
• bzr: https://tahoe-lafs.org/trac/tahoe-lafs/wiki/TipsTricks#HostBazaarrepositories
• perforce: https://tahoe-lafs.org/trac/tahoe-lafs/wiki/TipsTricks#Perforcebackendstorage
Now once you have your revision control repository stored in LAFS,
there are two basic structures of access control you could have:
Access control pattern 1:
Alice has read and write access to repository A
Bob has read and write access to repository A
Access control pattern 2:
Alice has read-and-write access to repository A
Alice has read-only access to repository B
Bob has read-and-write access to repository B
Bob has read-only access to repository A
The latter is a lot like a common pattern that you see nowadays on
github, bitbucket, and launchpad, where each person has their own
personal repository and they are the only one with write access to it,
but they can choose to accept pull request from other people in order
to let other people's code into their repository.
If you choose access control pattern 1, then LAFS has to decide what
to do when Alice and Bob both write different contents to the repo at
the same time. LAFS is not good at that. It will at best just blow
away one person's changes in favor of the other person's changes. It
will at worst eat your entire repository.
If you choose access control pattern 2, then LAFS doesn't ever have to
decide what to do about that, and instead your revision control tool
has to decide what to do about it. Your revision control isn't good at
it, either, but at least that's not my problem.
Regards,
Zooko
More information about the tahoe-dev
mailing list