RFC: rollback commit in some situations
Robert Collins
robertc at robertcollins.net
Thu Aug 14 06:25:57 BST 2008
On Thu, 2008-08-14 at 01:00 -0400, Aaron Bentley wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Robert Collins wrote:
> > So, I think we should change the commit code to catch some exceptions
> > ( in particular the invalid delta ones) and cause the branch to
> > rollback.
>
> It seems like it would be better to not reference the commit until we
> know it can't raise these exceptions. Is that possible?
In general no (svn), but for bzr it seems possible - put it in the repo,
update the tree, update the branch tip. It does raise a different race
condition though - which is that if the tree change succeeds but the
branch change fails, you have a tree that is ahead of the branch
(equivalent to someone doing 'branch.uncommit()' while bound, without
your tree there to update in parallel).
I'm not sure which race is better :/.
-Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20080814/5630f9d8/attachment.pgp
More information about the bazaar
mailing list