Re: Compressing the AFTER TRIGGER queue

Поиск
Список
Период
Сортировка
От Dean Rasheed
Тема Re: Compressing the AFTER TRIGGER queue
Дата
Msg-id CAEZATCW5A47-hog46kOwtSXJf-fwkQfmnVp=OfiS_53B85bH_A@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Compressing the AFTER TRIGGER queue  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Compressing the AFTER TRIGGER queue  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 1 August 2011 17:49, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Dean Rasheed <dean.a.rasheed@gmail.com> writes:
>> I've been thinking some more about the long-standing problem of the
>> AFTER TRIGGER queue using too much memory, and I think that the
>> situation can be improved by using some basic compression.
>
>> Currently each event added to the AFTER TRIGGER queue uses 10 bytes
>> per trigger per row for INSERTs and DELETEs, and 16 for UPDATEs. The
>> attached patch reduces this down to just 1 byte in a number of common
>> cases.
>
> Ummm ... I only read the data structure comments, not the code, but I
> don't see where you store the second CTID for an update event?
>

Ah yes, I forgot to mention that bit. I'm using
&(tuple1.t_data->t_ctid) to get the second CTID from the old tuple. Is
that safe? As far as I could see, this would match the new tuple after
a heap update.

Regards,
Dean


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Compressing the AFTER TRIGGER queue
Следующее
От: Simon Riggs
Дата:
Сообщение: Re: One-Shot Plans