pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Nikolay Shaplov <n.shaplov@postgrespro.ru>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: [PROPOSAL] Move all am-related reloption code into src/backend/access/[am-name] and get rid of relopt_kind
Date: Tue, 24 May 2016 17:28:05 -0400
Message-ID: <20160524212805.GA462831@alvherre.pgsql> (raw)
In-Reply-To: <CA+TgmobC9MhnNAmyxEiwP__2u69OSfa6WZeMce825gbO+W-LLg@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

Robert Haas wrote:
> On Tue, May 24, 2016 at 10:12 AM, Nikolay Shaplov
> <n.shaplov@postgrespro.ru> wrote:
> > While working on patch for attribute options for indexes (see
> > http://www.postgresql.org/message-id/5213596.TqFRiqmCTe@nataraj-amd64 )
> > I found out that code for reloptions is not flexible at all.
> >
> > All definitions of attoptons are stored in central catalog in
> > src/backend/access/common/reloptions.c
> > It is done this way for both heap and tuple relations, and also for all index
> > access methods that goes with source code.
> >
> > Most of the code of the indexes is now hidden behind
> > "access method" abstraction, but not the reloption code. If you grep through
> > src/backend/access/common/reloptions.c, you will find RELOPT_KIND_GIN,
> > RELOPT_KIND_BTREE, RELOPT_KIND_GIST, RELOPT_KIND_SPGIST, RELOPT_KIND_BRIN...
> >
> > This all should me moved behind "access method" abstraction...
> 
> +1 for that concept.  I'm not sure whether your implementation is good
> or bad because I haven't really looked at it, but I agree that the way
> the reloption stuff is structured is a nuisance, and injecting more
> abstraction there seems like a good thing.

As the author of the old stuff, I agree.

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers



view thread (46+ messages)  latest in thread

Message-ID: <20160524212805.GA462831@alvherre.pgsql>
Permalink:  ../20160524212805.GA462831@alvherre.pgsql/
Also on:    postgresql.org/message-id/20160524212805.GA462831@alvherre.pgsql

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: alvherre@2ndquadrant.com, robertmhaas@gmail.com, n.shaplov@postgrespro.ru
  Subject: Re: [PROPOSAL] Move all am-related reloption code into src/backend/access/[am-name] and get rid of relopt_kind
  In-Reply-To: <20160524212805.GA462831@alvherre.pgsql>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox