From: | JanWieck(at)t-online(dot)de (Jan Wieck) |
---|---|
To: | PostgreSQL HACKERS <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: AW: update on TOAST status' |
Date: | 2000-07-11 16:49:58 |
Message-ID: | 200007111649.SAA18903@hot.jw.home |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Zeugswetter Andreas SB wrote:
>
> > It appears that brtee indices (at least) can keep references
> > to old toast values that survive a VACUUM! Seems these
> > references live in nodes actually not referring to a heap
> > tuple any more, but used during tree traversal in
> > comparisions. As if an index tuple delete from a btree not
> > necessarily causes the index value to disappear from the
> > btree completely. It'll never be returned by an index scan,
> > but the value is still there somewhere.
>
> Would it be possible to actually delete those entries during vacuum ?
> I guess that would be an overall win, no ?
Seems I explained it a little confusing or am confused by it
myself.
Either way, VACUUM does DELETE those from the indices! But
btree is a Balanced Tree, and ISTM that it sometimes decides
to keep a deleted node just to have trees balanced and to
decide on it whether to go left or right. An index scan will
never return those nodes, but exactly at the time btree needs
to decide left/right, it calls the type specific CMP function
and that in turn invokes the toast fetch.
A pure btree does not have the need for it, but we're using a
high concurrency optimized version called nbtree. That one
seems to do so.
Jan
--
#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#================================================== JanWieck(at)Yahoo(dot)com #
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2000-07-11 16:49:59 | Re: md5 again |
Previous Message | Vince Vielhaber | 2000-07-11 16:49:32 | Re: md5 again |