Re: BUG #18280: logical decoding build wrong snapshot for subtransactions

Поиск
Список
Период
Сортировка
От feichanghong
Тема Re: BUG #18280: logical decoding build wrong snapshot for subtransactions
Дата
Msg-id tencent_D07767F0078E09240737829D12D97B530606@qq.com
обсуждение исходный текст
Ответ на Re: BUG #18280: logical decoding build wrong snapshot for subtransactions  (Amit Kapila <amit.kapila16@gmail.com>)
Список pgsql-bugs
Thank you for your correction.

On Jan 24, 2024, at 17:18, Amit Kapila <amit.kapila16@gmail.com> wrote:

While looking closely at the test result, I wondered how the following
part of test "s0_begin" "s0_truncate" "s1_checkpoint" "s1_get_changes"
"s0_insert_part" "s1_get_changes" "s0_commit" can see the insert when
the containing transaction is not yet committed. Then, I found it is
because the insert is performed from session 1 due to way it is
declared.

session "s1"
...
step "s1_get_changes" { SELECT data FROM
pg_logical_slot_get_changes('isolation_slot', NULL, NULL,
'skip-empty-xacts', '1', 'include-xids', '0'); }
+step "s0_insert_part" { INSERT INTO tbl1_part VALUES (1); }

I think this session should be performed from seesion-1 and we need
one more get_changes() call to see the problem. I have modified the
test accordingly and also changed the comments. See the attached and
let me know what you people think.

I'm very sorry for confusing you due to my mistake. In my original patch,
"s0_insert_part" should be "s1_insert_part" in session "s1", and after
confirmation, the problem can be reproduced.
Of course your fix is totally correct for me.


Best Regards,
Fei Changhong
Alibaba Cloud Computing Ltd.

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

Предыдущее
От: gparc@free.fr
Дата:
Сообщение: Re: BUG #18295: In PostgreSQL a unique index on targeted columns is sufficient to support a foreign key
Следующее
От: PG Bug reporting form
Дата:
Сообщение: BUG #18309: TOASTed entry in pg_subscription provokes an assertion failure