Re: replace oidrand() with random_sample()

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Neil Conway <neilc(at)samurai(dot)com>
Cc: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: replace oidrand() with random_sample()
Date: 2003-01-16 04:26:07
Message-ID: 11482.1042691167@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

Neil Conway <neilc(at)samurai(dot)com> writes:
>> I agree that oidrand() is crufty and no longer useful, but I had
>> hesitated to rip it out, for fear that somebody somewhere might still
>> be using it. It's not like it's costing us any maintenance effort
>> to leave it there.

> Keep in mind that it was undocumented and strangely named -- while there
> might be some people using it, I'd wager not many.

True enough.

> Whether we leave it in or not, I'd vote for eventually getting rid of
> the current version. So if we keep it, we could add random_sample() and
> keep oidrand() as a wrapper over it (that emits an elog(WARNING) to let
> people know it's been deprecated). And if we want to get rid of it, we
> could probably just add the elog() for 7.4 and then remove it outright
> in 7.5.

Well, now you're adding a whole lot of maintenance effort to support
some quite-hypothetical users of a function we all agree is junk ;-)

I think we should either leave it be, or rip it out and be done with it.
I don't actually much care which (does anyone out there have an
opinion?). But a phased-obsolescence plan is far more work than it
deserves.

regards, tom lane

In response to

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Bruce Momjian 2003-01-16 04:27:15 Re: replace oidrand() with random_sample()
Previous Message Neil Conway 2003-01-16 02:08:39 Re: replace oidrand() with random_sample()