From: H. Peter Anvin Date: Wed, 24 Jan 2007 16:24:22 GMT Subject: Re: .git/info/refs Message-ID: <45B78836.5080508@zytor.com> In-Reply-To: Johannes Schindelin wrote: > > To me, it seems like all boils down to caching parsed data structures. > I.e. parse the config, then serialize the parsed data to a file. Don't > reparse the config unless it is 1 hour older than the config. > > Likewise, run for-each-ref, and serialize the parsed data into a file. > Don't rerun for-each-ref if that file is younger than 15 minutes. > > Maybe the same for the first 200 commits of each branch. > > (I made those times up, but you get the idea.) > A much better idea is to have that data structure updated on repository updates, which is the whole point behind .git/info/refs. On kernel.org, at least, if you don't keep .git/info/refs up to date you need to get your fingers whacked anyway, since it damages usability for one particular class of users. -hpa