[darcs-users] Faster get proposal

David Roundy droundy at abridgegame.org
Wed Dec 8 12:47:28 UTC 2004


On Wed, Dec 08, 2004 at 12:22:45AM +0200, Einar Karttunen wrote:
> On 07.12 22:59, Karel Gardas wrote:
> > isn't checkpoint feature what you would like to use?
> > Please read `What do you do when you've got lots of patches and releases
> > in a repository?' on http://www.scannedinavian.org/DarcsWiki/BestPractices
> 
> No that is not a really good solution. 
> 
> This is because:
> * Random users won't use extra options

Random users will do whatever you tell them to! If your website says "You
can get the latest code using 'darcs get --partial http://foo.com/repo'",
that's what they'll do.

> * Serious users want usually the whole thing

True.

> * Having one large patch makes darcs very slow

Indeed.

> This proposal could eliminate the problem of very slow darcs get for large 
> (think linux kernel) repositories. 

Basically, your idea is to special-case the checkpoint scheme and use it
even when getting a complete repository, to avoid having to apply all the
patches.  It's a reasonable idea.  I'd rather not use tar to do it, since
then we'd potentially have to deal with incompatible/unavailable tars.

Allowing a --with-checkpoint option, or something like that, would be a
reasonable idea though, as a starting point.  Your method shouldn't be the
only option, since it trades off bandwidth for speed, and that tradeoff
won't be beneficial for slow connections or repositories with short
histories.  We'd then need to special-case the applying of a single patch
to an empty repository.  We'd still not be as fast as tar, since we'd still
have to parse the lines, and write the files line-by-line.  But I don't
think that would hurt too much, and by using a darcs patch instead of a
tarball, we keep the pathways open for things like keeping track of
additional metadata.
-- 
David Roundy
http://www.darcs.net




More information about the darcs-users mailing list