RFC: A mercurial pack extension

Mark Williamson mark.williamson at cl.cam.ac.uk
Tue Feb 19 00:55:37 CST 2008


> > I imagine the ability to automatically upload bundles (e.g. over FTP, SSH
> > or even HTTP to a server) could be useful for those who don't have easy
> > access to CGI and end up doing everything via bundles?  It'd be quite
> > neat useability-wise to be able to do something like this...
>
> This is exactly the situation we found ourselves in (no longer, luckily).

I can get CGI but it's less convenient so I like solutions that make it easier 
to avoid this.

> > I actually wonder if it'd be technically possible to extend an existing
> > bundle, which could make "push" to a bundle a sensible operation...  I
> > can dream ;-)
>
> From what I've read about hg's design (a very impressive read, I might
> add), I think at this point you cannot. It is a stream of the
> changegroups for the changelog, then for the manifest, then for the
> files (in sorted order). And its compressed as a single stream.
>
> You could, I guess, just append another such stream, but I think no
> reading code is prepared for that.

There's a version string, so I guess you could bump the revision of the 
bundle.  Not ideal though.  I'll have to read up on the format.

> While this would probably be easy 
> to extend, it would defeat one of the key aims mpm had for the bundle
> format, namely streaming out changes in an order that is optimized for
> efficient processing by the underlying filesystem and disk (seeks, in
> particular). And it would compress less.

Yep.  It'd be nice to be able to add to a bundle primarily so you could add 
stuff on to an already published bundle.  I guess whether that's worth it 
depends on the relative bandwidth between the various parties involved, size 
of changes, etc.

> The key benefit of such a thing would be when updating remote repos.
> But you cannot append to a file over FTP anyway, or can you?

I don't know to be honest.  Thing is, usually I have SSH (or other) access to 
my fileserver, I'm just stuck with plain HTTP for downloads from it.  So it's 
easy for me to do tricky things with sending new bundles to it, I just can't 
require any intelligence from the HTTP server.

Cheers,
Mark

-- 
Push Me Pull You - Distributed SCM tool (http://www.cl.cam.ac.uk/~maw48/pmpu/)


More information about the Mercurial mailing list