[RFC] Bundles as repositories

Robert Collins robertc at robertcollins.net
Fri Jun 15 06:05:00 BST 2007


I think this has been roughly discussed, but wanted to be sure it had..

I think we want a compact binary bundle format, with the human text
overall delta just an ignored-prelude. We can check the prelude matches
the binary data when processing, or encourage people to run the bundle
through bzr... Alternatively we could have no human readable section but
a specific mime type so mutt etc can get bzr to format it for human
reading.

AIUI we want bundles to have the following properties:
 - compact representation
 - able to be used without their contained data being added to
repositories 
 - fast to create
 - fast to extract data from

And we are building towards a repository format that:
 - can discard derivable data
 - is fast to use
 - can be used for 'lightweight branches' aka 'history horizons' - where
not all data is present, and we have a 'stacking api' to get at the
missing data from somewhere else seamlessly.

To me it makes sense that bundles should then be a
'branch-and-repository-in-a-file':
 - one with the derivable data discarded
 - one where the data within it has been stored in the most compact
representation
 - one that only contains partial history data

This will meet the properties desired from bundles, and would allow us
to remove the special-casing for pull/missing/merge etc from bundles
(bundles would be detected as a control format so any command using
BzrDir.open would work with them).

We can't do this today because there are many missing components, but I
think we can work towards it quite quickly, and I'd be delighted to
propose some incremental steps.

The actual representation might look something like:
the bundle is a pack file.
The pack contains records named:
branch-data
  tip revision id
  branch nick
branch-tags
  tag ...
[repository data here, representation still unclear to me, though I'm
sure Aaron has some solid thoughts on this as he has been hacking on
something that is conceptually very similar]

If this is agreeable, I'll create a design document trying to ensure we
have solid motivation and so on documented.

-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/20070615/808663a3/attachment.pgp 


More information about the bazaar mailing list