Compressing weaved revisions?

John A Meinel john at arbash-meinel.com
Fri Sep 30 17:20:44 BST 2005


Aaron Bentley wrote:
> Hi all,
> 
> For trees with, e.g. 500 revisions, the revision storage may actually be
> larger than tree storage.
> 
> The new format doesn't weave revisions, because they're almost
> completely different for each revision.  They also don't compress well.
>  For my example tree, the revisions are 47 k uncompressed and 32 k
> compressed.

Actually, if you look at storage on disk, things get even worse, 
considering that each 400 byte file, takes up a 4k disk block.

$ du -ksh .bzr/revision-store/
7.2M    .bzr/revision-store/
$ du -ksh --apparent .bzr/revision-store/
755K    .bzr/revision-store/

Now, I'm on reiserfs, but I don't know that du knows about that.

> 
> But if they're tarred and gzipped, the tarfile is 7.2k, and if they're
> tarred and bzipped, that's 5.7k.
> 
> I expect if revisions were weaved and gzipped, we'd see roughly the same
> level of compression, i.e. 6x
> 
> They would have the disadvantages of weaves, but we've already accepted
> those disadvantages for texts and inventories.

If I recall from the earlier discussion, revision-store wasn't weaved 
because as you mentioned, it didn't weave very well, and you lose the 
ability to have O(1) index lookup.

However, since we seem to pull everything locally, and merge everything 
(including inventories and texts) into the local branch before we do any 
other work, this may not really matter.

Are there plans to write the weaves in compressed format? Certainly the 
file format would support it, since you reread and rewrite the entire 
file each time, but is it genuinely worth it to compress it? Probably we 
should play with it, and see how long it takes to read the file, versus 
how much compression we get.

John
=:->

> 
> Aaron
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 253 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20050930/04699bb0/attachment.pgp 


More information about the bazaar mailing list