Comment 3 for bug 491806

Revision history for this message
Jelmer Vernooij (jelmer) wrote : Re: [Bug 491806] Re: caching should be enabled for file:// urls that point to network shares/NFS locations

On Thu, 2009-12-10 at 18:02 +0000, Kuno wrote:
> During the "analyse repository layout" phase, bzr-svn reads all files in
> "db\revs\" and "db\revprops", starting from the latest revision down to
> revision 1. This means that there are O(# of SVN revs) roundtrips, which
> is very costly even for small repositories.
To determine the repository layout it does this only for the last 400 or
so revisions.

When using a cache, it has to walk over all revisions anyway to fill the
cache. Accessing the cache also requires disk access as well as some
access (although less) to the repository itself. It also uses extra disk
space in the users home directory.

Furthermore, the cache is stored in the users home directory, which may
also be on NFS.

> The effect of caching is therefore easily perceptible (although I didn't
> measure it): "bzr update" for a bound branch of a repo with ~120 revs
> takes >30-40s in the non-cached case, but ~4s with caching...
I strongly doubt this; I'm willing to be convinced to change the
heuristics that determine whether to use the cache but please suggest
benchmarks and suggest better heuristics.

Cheers,

Jelmer