[MERGE][1.8?] Make 'bzr co' more memory sensitive
John Arbash Meinel
john at arbash-meinel.com
Fri Oct 10 21:19:20 BST 2008
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Vincent Ladeuil wrote:
>>>>>> "john" == John Arbash Meinel <john at arbash-meinel.com> writes:
>
> john> Vincent Ladeuil wrote:
> john> ...
>
> john> + """For the given keys, split them up based on their prefix.
> john> +
> john> + To keep memory pressure somewhat under control, split the
> john> + requests back into per-file-id requests, otherwise "bzr co"
> john> + extracts the full tree into memory before writing it to disk.
> john> + This should be revisited if _get_content_maps() can ever cross
> john> + file-id boundaries.
> >>
> >> Can you write a test guarding from regression on that particular
> >> case ?
> >>
> >> BB:tweak
> >>
> >> Convert that to approve from me if the test above is really too
> >> hard to get right, but in that case, add a FIXME.
>
> john> I don't really know how to write a correct test (that
> john> maximum memory is constrained).
>
> I meant regression on "_get_content_maps() can ever cross file-id
> boundaries.".
>
> Vincent
>
I honestly don't know how we would do it. Because I don't know how we
would end up implementing cross-file-id storage, and thus how to
*trigger* that in real life.
If that is your only request, then I can submit the patch as is. (Note
that I did work out a patch which adds an explicit test case, I just
don't like it because it needs 100MB of ram and disk space, and takes
60s to finish.)
John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkjvuMgACgkQJdeBCYSNAAPAKgCbBR1TwwOhejbajOjHPd2dmPJm
hC4AoNKmtTLpIemoCmnNCWnIlkWLNB2w
=ON8A
-----END PGP SIGNATURE-----
More information about the bazaar
mailing list