From: | Greg Stark <greg(dot)stark(at)enterprisedb(dot)com> |
---|---|
To: | Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com> |
Cc: | Pavan Deolasee <pavan(dot)deolasee(at)gmail(dot)com>, Jeff Davis <pgsql(at)j-davis(dot)com>, Kenneth Marshall <ktm(at)rice(dot)edu>, Jaime Casanova <jcasanov(at)systemguards(dot)com(dot)ec>, Simon Riggs <simon(at)2ndquadrant(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Preventing index scans for non-recoverable index AMs |
Date: | 2008-12-18 13:20:26 |
Message-ID: | C53F2E20-309A-4154-9873-1BD0185065D8@enterprisedb.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
It would be perfectly reasonable to add an amisrecoverable like Simon
described. It could automatically set indisvalid to false after a
crash and treat the index as if indisvalid is false during recovery.
That would be a lot smoother and safer than what we have now.
It might even be possible to do this with a new wal record type so it
only happens if there was a write to the index. I imagine most users
who read that warning and use hash indexes anyways are using them on
read-only tables where they know it's safe.
--
Greg
On 18 Dec 2008, at 07:51, Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com
> wrote:
> Pavan Deolasee wrote:
>> BTW, if there is no proven case where hash index works significantly
>> better than btree (that's what the doc says), why not just completely
>> abandon it ?
>
> That has been considered many times, see archives. I believe the
> changes done in 8.4 actually made it faster for some cases. And as
> Kenneth pointed out hash indexes can handle keys larger than 1/3 of
> page size, that b-tree can't.
>
> --
> Heikki Linnakangas
> EnterpriseDB http://www.enterprisedb.com
>
> --
> Sent via pgsql-hackers mailing list (pgsql-hackers(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-hackers
From | Date | Subject | |
---|---|---|---|
Next Message | Emmanuel Cecchet | 2008-12-18 13:41:04 | Re: Partitioning wiki page |
Previous Message | Heikki Linnakangas | 2008-12-18 13:13:55 | Re: Latest version of Hot Standby patch |