Skip site navigation (1) Skip section navigation (2)

Preliminary patch for tsearch example dictionaries/parsers in contrib

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-patches(at)postgreSQL(dot)org
Cc: Oleg Bartunov <oleg(at)sai(dot)msu(dot)su>, Sergey Karpov <karpov(at)sao(dot)ru>
Subject: Preliminary patch for tsearch example dictionaries/parsers in contrib
Date: 2007-10-08 23:25:14
Message-ID: 3049.1191885914@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-patches
Given all the flap about txid, this surely mustn't go in without public
review first ;-).  So, here is a submission from Sergey Karpov to fill
in the lack of any working code examples for user-written tsearch
parsers and dictionaries.

I will be mostly off-line for the next day or so and don't have time to
work on this more now, but here are a few comments:

* It seems a bit odd to put multiple independent contrib modules under a
single subfolder.  I'd be inclined to drop the ts_pack layer and just
make the dictionaries and parser be top-level contrib modules.

* Depending on PCRE, when we have an at-least-equally-good regex engine
built in, is silly.  It's an unnecessary dependency and to the (minor)
extent that the regex syntax is different, we'd have to document the
discrepancies.

* dict_regex is not nearly up to speed on encoding or locale issues.
I didn't look at the other ones too closely, they may or may not need
similar adjustments.

* Allowing config files to be read from anywhere is not acceptable.
We have dealt with this in the core code and the contrib examples
*must* follow the same rules.

* The whole "utils" part of dict_regex should probably go away; it
is reinventing wheels that already exist in the Postgres backend
environment.  Since these are meant to be code examples, they should
show the best ways of doing things within Postgres.

			regards, tom lane


Attachment: ts_pack.tar.gz
Description: application/octet-stream (41.0 KB)

Responses

pgsql-patches by date

Next:From: Bruce MomjianDate: 2007-10-09 00:20:45
Subject: Re: Patch to inline stable SQL set returning UDFs
Previous:From: Tom LaneDate: 2007-10-08 22:09:25
Subject: Re: txid strtoull fix

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group