Re: [HACKERS] REPLICA IDENTITY FULL

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: [HACKERS] REPLICA IDENTITY FULL
Дата
Msg-id 20170623171022.ihdoj45p3ovubd5e@alap3.anarazel.de
обсуждение исходный текст
Ответ на Re: [HACKERS] REPLICA IDENTITY FULL  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Ответы Re: [HACKERS] REPLICA IDENTITY FULL  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Список pgsql-hackers
On 2017-06-23 13:05:21 -0400, Alvaro Herrera wrote:
> Tom Lane wrote:
> > Peter Eisentraut <peter.eisentraut@2ndquadrant.com> writes:
> > > Any thoughts about keeping datumAsEqual() as a first check?  I did some
> > > light performance tests, but it was inconclusive.
> > 
> > Seems like it would tend to be a win if, in fact, the values are
> > usually equal.  If they're usually not, then it's a loser.  Do
> > we have any feeling for which case is more common?

Seems like a premature optimization to me - if you care about
performance and do this frequently, you're not going to end up using
FULL.  If we want to performance optimize, it'd probably better to
lookup candidate keys and use those if available.


> Though, thinking about it, maybe the datumIsEqual test would give the
> wrong answer for floating point values, and there'd be no fallback to
> equality with the logic I propose.  But then maybe that's all
> right ---

I don't think it'd be ok, we shouldn't just do the wrong thing because
we think it's unlikely to happen.


> who in their right minds would use floating point columns as part of
> replica identity ...?

Since this is FULL, it'll be all columns...


- Andres



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: [HACKERS] REPLICA IDENTITY FULL
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: [HACKERS] REPLICA IDENTITY FULL