[MERGE] Initialize before transfer for BzrDir.clone() and sprout()

Robert Collins robertc at robertcollins.net
Sun Feb 4 12:58:40 GMT 2007


On Sun, 2007-02-04 at 13:44 +0100, Jelmer Vernooij wrote:
> On Sun, 2007-02-04 at 07:37 -0500, Robert Collins wrote:
> > I think the basic tension is whether branch/push operations should be 
> > resumable on error or not.
> I really think they should be. Imagine having a connection dropped while
> pulling in a large branch. I can't think of a reason why having resume
> support would not be a good idea.

so there is a difference between:

bzr push A &;
sleep 5
kill %1
bzr push A

being resumable, and

bzr branch A  B &;
sleep 5
kill %1
cd B
bzr pull

In the former case we do *not* need the target branch object, we only
need the target repository, to perform resumable pushes. (And in fact,
with johns patch to improve push, this is what we have).

In the latter case, we require the branch object to all 'pull' to
determine where to pull from, and what branch to update.

Changing sprout() - which would alter branch - to create a branch object
immediately fixes the latter use case. Changing clone() - which alters
push - to create one *does not affect* the former use case, but does
introduce a race condition where other users see an empty branch which
may not ever be completely populated because the push has not even
completed once).

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/20070204/e8b307f8/attachment.pgp 


More information about the bazaar mailing list