[MERGE/RFC] Branch.merge_sorted_revisions

John Arbash Meinel john at arbash-meinel.com
Wed Jan 21 01:26:33 GMT 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Ian Clatworthy wrote:
> This patch proposes a new API for Branch called
> merge_sorted_revisions(). The implementation of
> get_revision_id_to_revno_map() has been
> refactored to use this new method.
> 
> Assuming this API is OK by everyone, the next step
> is to refactor log/missing/annotate/etc. to use
> this method (rather than reimplement the same
> block of code as they currently do).
> 
> I'm also hoping to use this hook in my revnocache
> plugin, i.e. cache the merge graph and not just
> the revid => revno part of it.
> 
> Ian C.
> 

BB:comment

Ultimately I don't think an api like this will "scale". Because it
always describes the full history of revisions. I think it might be okay
as a stepping point (and certainly works better with your revno-cache),
but it seems like you would want something that allows you to give a
subset via some fashion. Not to mention being able to iterate forward or
reverse.

So if it is a step towards something more efficient, it is probably ok,
but I wouldn't really want to introduce an api that requires O(history)
as part of its definition.

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkl2eckACgkQJdeBCYSNAAO31wCeKmyOg3YiaCsVu0bNPJr2dr1e
bfAAn10IPZ7zHEJE/lOWcJkUEQk+M6zy
=S2tk
-----END PGP SIGNATURE-----



More information about the bazaar mailing list