Re: pg_stat_advisor extension

From: Ilia Evdokimov <ilya(dot)evdokimov(at)tantorlabs(dot)com>
To: pgsql-hackers(at)postgresql(dot)org, a(dot)lepikhov(at)postgrespro(dot)ru
Subject: Re: pg_stat_advisor extension
Date: 2024-02-08 14:24:06
Message-ID: 5952b149-afb5-4461-a983-a41f800b1927@tantorlabs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Feb 08 2024 at 07:14:18, Andrei Lepikhov wrote:

> 1. In the case of parallel workers the plan_rows value has a different
> semantics than the number of rows predicted. Just explore
> get_parallel_divisor().
Yes, this is a very weighty and important issue. I need to think about
this very carefully.
>2. The extension recommends new statistics immediately upon an error
>finding. But what if the reason for the error is stale statistics? Or
>this error may be raised for only one specific set of constants, and
>estimation will be done well in another 99.9999% of cases for the same
>expression.
>According to No.2, it might make sense to collect and track clause
>combinations and cardinality errors found and let the DBA make decisions
>on their own.
Your proposal is very interesting. In my opinion, it is worth
considering updating the extended statistics if they are truly stale.
And write about this in a separate message with suggestion updating
statistics.
If I succeed, then in the next patch I will add the kind of extended
statistics to the message, deal with the parallel workers and update
statistics if necessary.
If you have additional suggestions and thoughts, feel free to write them
in this thread.

Regards,
Ilia Evdokimov,
Tantor Labs LLC.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Maiquel Grassi 2024-02-08 14:58:19 RE: Psql meta-command conninfo+
Previous Message Hayato Kuroda (Fujitsu) 2024-02-08 14:22:21 RE: speed up a logical replica setup