Re: Adding a test for speculative insert abort case

Поиск
Список
Период
Сортировка
От Melanie Plageman
Тема Re: Adding a test for speculative insert abort case
Дата
Msg-id CAAKRu_ZhkHPpFP1gxNYDvX-M_AGworGgS05eJfxOHp_hYZiDvA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Adding a test for speculative insert abort case  (Ashwin Agrawal <aagrawal@pivotal.io>)
Ответы Re: Adding a test for speculative insert abort case  (Andres Freund <andres@anarazel.de>)
Список pgsql-hackers


On Wed, May 15, 2019 at 10:32 PM Ashwin Agrawal <aagrawal@pivotal.io> wrote:

The second index would help to hold the session after inserting the tuple in unique index but before completing the speculative insert. Hence, helps to create the condition easily. I believe order of index insertion is helping here that unique index is inserted and then non-unique index is inserted too.


Oh, cool. I didn't know that execution order would be guaranteed for which index
to insert into first.
 
Attaching patch with the test using the idea Andres mentioned and it works to excercise the speculative wait.


It looks good.
I thought it would be helpful to mention why you have s1 create the non-unique
index after the permutation has begun. You don't want this index to influence
the behavior of the other permutations--this part makes sense. However, why have
s1 do it instead of the controller?

I added a couple suggested changes to the comments in the permutation in the
version in the patch I attached. Note that I did not update the answer files.
(These suggested changes to comments are in distinct from and would be in
addition to the suggestions I had for the wording of the comments overall in the
above email I sent).

--
Melanie Plageman
Вложения

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

Предыдущее
От: Peter Geoghegan
Дата:
Сообщение: Re: VACUUM can finish an interrupted nbtree page split -- is that okay?
Следующее
От: Andres Freund
Дата:
Сообщение: Re: Adding a test for speculative insert abort case