[MERGE] btree prefetch

Martin Pool mbp at canonical.com
Wed Oct 29 00:50:28 GMT 2008

On Wed, Oct 29, 2008 at 6:38 AM, John Arbash Meinel
<john at arbash-meinel.com> wrote:
>> It looks like you're searching for integers in a set of key tuples, which
>> would presumably never match?
> The key for a page is actually the integer offset. (So the page at bytes
> 4096-8191 is at offset 1 and uses key == 1.)
> I called it "_get_cached_keys" because I'm not getting the bytes to the
> pages themselves (to say get_cached_pages). "get_cached_offsets" doesn't
> quite work either. Perhaps "get_offsets_to_cached_pages" ?
> The code, in general, is bad about terminology. Sometimes calling it
> 'nodes', sometimes calling it 'pages', etc. I'll do a pass which changes
> references to the *key* for a page to use terms like "offset".
> There is also the possibility to use the "node_index" terminology, but
> as the class is a BTreeIndex, that is double-overloading 'index' as well...

I think if they're byte offsets then 'offset' or maybe 'position'
would be good.  'key' is fairly strongly associated with tuple keys.

Martin <http://launchpad.net/~mbp/>

More information about the bazaar mailing list