Re: Hash Indexes

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Oskari Saarenmaa <os(at)ohmu(dot)fi>, Bruce Momjian <bruce(at)momjian(dot)us>, Jeff Janes <jeff(dot)janes(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Hash Indexes
Date: 2016-09-23 19:19:14
Message-ID: CA+TgmoaPJ7na9Z7c1uiStr9tVOG7V2FhDk0iaAu5p8-Mds8xZA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Sep 21, 2016 at 10:33 PM, Andres Freund <andres(at)anarazel(dot)de> wrote:
> On 2016-09-21 22:23:27 -0400, Tom Lane wrote:
>> Andres Freund <andres(at)anarazel(dot)de> writes:
>> > Sure. But that can be addressed, with a lot less effort than fixing and
>> > maintaining the hash indexes, by adding the ability to do that
>> > transparently using btree indexes + a recheck internally. How that
>> > compares efficiency-wise is unclear as of now. But I do think it's
>> > something we should measure before committing the new code.
>>
>> TBH, I think we should reject that argument out of hand. If someone
>> wants to spend time developing a hash-wrapper-around-btree AM, they're
>> welcome to do so. But to kick the hash AM as such to the curb is to say
>> "sorry, there will never be O(1) index lookups in Postgres".
>
> Note that I'm explicitly *not* saying that. I just would like to see
> actual comparisons being made before investing significant amounts of
> code and related effort being invested in fixing the current hash table
> implementation. And I haven't seen a lot of that. If the result of that
> comparison is that hash-indexes actually perform very well: Great!

Yeah, I just don't agree with that. I don't think we have any policy
that you can't develop A and get it committed unless you try every
alternative that some other community member thinks might be better in
the long run first. If we adopt such a policy, we'll have no
developers and no new features. Also, in this particular case, I
think there's no evidence that the alternative you are proposing would
actually be better or less work to maintain.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jim Nasby 2016-09-23 19:27:27 Re: PL/Python adding support for multi-dimensional arrays
Previous Message Robert Haas 2016-09-23 19:10:20 Re: Rename max_parallel_degree?