Re: How to implement a SP-GiST index as a extension module?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Alexander Korotkov <a(dot)korotkov(at)postgrespro(dot)ru>
Cc: Oleg Bartunov <obartunov(at)gmail(dot)com>, Connor Wolf <wolf(at)imaginaryindustries(dot)com>, Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: How to implement a SP-GiST index as a extension module?
Date: 2017-10-30 14:40:50
Message-ID: 18347.1509374450@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Alexander Korotkov <a(dot)korotkov(at)postgrespro(dot)ru> writes:
> I think Connor struggles to implement just an operator class. Advising him
> to implement an index access method is a good way to get him away of
> PostgreSQL hacking for a long time :)

Yeah. To answer the question a bit more directly: there are not any
contrib modules that add SP-GiST opclasses, but there are some that add
GiST or GIN opclasses, so any one of those would serve as a model for the
basic mechanism of writing an extension. Just replace the AM-specific
support functions for those AMs with the ones SP-GiST uses. (You can crib
some code details from the in-core SP-GiST support functions.)

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2017-10-30 14:51:34 Re: Remove secondary checkpoint
Previous Message Michael Paquier 2017-10-30 14:31:24 Re: Remove secondary checkpoint