Re: Proposal: syntax of operation with tsearch's configuration - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: Proposal: syntax of operation with tsearch's configuration
Date
Msg-id 20061117204237.GA5293@alvh.no-ip.org
Whole thread Raw
In response to Re: Proposal: syntax of operation with tsearch's configuration  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Proposal: syntax of operation with tsearch's configuration  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom Lane wrote:
> Alvaro Herrera <alvherre@commandprompt.com> writes:
> > I also think the "thousands of lines" is an exaggeration :-)
> 
> I think a reasonable comparison point is the operator-class commands,
> which are at least in the same general ballpark of complexity.
> opclasscmds.c is currently 1075 lines, and that's not counting the
> grammar additions, nor miscellaneous bits of support in places like
> backend/nodes/, dependency.c if you expect to be able to DROP the
> objects, namespace.c if they live in schemas, aclchk.c if they have
> owners or permissions, comment.c, etc.  Teodor is proposing to add not
> one but four new kinds of system objects.  In round numbers I would
> bet that such a patch will add a lot closer to 10000 lines than 1000.
> 
> It may be worth doing anyway --- certainly CREATE OPERATOR CLASS was a
> huge improvement over the previous ways of doing it --- but don't
> underestimate the size of what we're talking about.

Hmm, actually the tsearch2 directory contains 16500 lines of code
(generated using David A. Wheeler's 'SLOCCount'), so I didn't doubt that
it's a big piece of code as a whole -- but I thought what was being
discussed was the size of the grammar changes, which is why I mentioned
the "a couple dozen" figure.

Having the supporting code in core does not make much of a difference
otherwise from having it in contrib, does it?

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Proposal: syntax of operation with tsearch's configuration
Next
From: Oleg Bartunov
Date:
Subject: Re: Proposal: syntax of operation with tsearch's configuration