Re: [PATCH] Add extra statistics to explain for Nested Loop

Поиск
Список
Период
Сортировка
От e.sokolova@postgrespro.ru
Тема Re: [PATCH] Add extra statistics to explain for Nested Loop
Дата
Msg-id 35976aa41e4ca6f7782d336e7758636e@postgrespro.ru
обсуждение исходный текст
Ответ на Re: [PATCH] Add extra statistics to explain for Nested Loop  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
Ответы Re: [PATCH] Add extra statistics to explain for Nested Loop
Список pgsql-hackers
Tomas Vondra писал 2020-10-31 04:20:

> seems like an interesting and useful improvement. I did a quick review
> of the patch - attached is a 0002 patch with a couple minor changes 
> (the
> 0001 is just your v1 patch, to keep cfbot happy).

  Thank you for your review and changes!

> 3) In ExplainNode, in the part processing per-worker stats, I think 
> some
> of the fields are incorrectly referencing planstate->instrument instead
> of using the 'instrument' variable from WorkerInstrumentation.

It's correct behavior because of struct WorkerInstrumentation contains 
struct Instrumentation instrument. But planstate->instrument is struct 
Instrumentation too.

> I wonder if we should have another option EXPLAIN option enabling this.
> I.e. by default we'd not collect/print this, and users would have to
> pass some option to EXPLAIN. Or maybe we could tie this to VERBOSE?

It's good idea. Now additional statistics are only printed when we set 
the VERBOSE.

New version of this patch prints extra statistics for all cases of 
multiple loops, not only for Nested Loop. Also I fixed the example by 
adding VERBOSE.

Please don't hesitate to share any thoughts on this topic!
-- 
Ekaterina Sokolova
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company
Вложения

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Add important info about ANALYZE after create Functional Index
Следующее
От: Eugen Konkov
Дата:
Сообщение: Re: Proposition for autoname columns