On 2023-Oct-09, Imseih (AWS), Sami wrote:
> > I think we should definitely be afraid of that. I am in favor of a
> > separate GUC.
I agree.
> Currently explain ( analyze ) will give you the "Workers Planned"
> and "Workers launched". Logging this via auto_explain is possible, so I am
> not sure we need additional GUCs or debug levels for this info.
>
> -> Gather (cost=10430.00..10430.01 rows=2 width=8) (actual tim
> e=131.826..134.325 rows=3 loops=1)
> Workers Planned: 2
> Workers Launched: 2
I don't think autoexplain is a good substitute for the originally
proposed log line. The possibility for log bloat is enormous. Some
explain plans are gigantic, and I doubt people can afford that kind of
log traffic just in case these numbers don't match.
> Adding cumulative stats is a much better idea.
Well, if you read Benoit's earlier proposal at [1] you'll see that he
does propose to have some cumulative stats; this LOG line he proposes
here is not a substitute for stats, but rather a complement. I don't
see any reason to reject this patch even if we do get stats.
Also, we do have a patch on stats, by Sotolongo and Bonne here [2]. I
think there was some drift on the scope, so eventually they gave up (I
don't blame them). If you have concrete ideas on what direction that
effort should take, I think that thread would welcome that. I have not
reviewed it myself, and I'm not sure when I'll have time for that.
[1] https://postgr.es/m/d657df20-c4bf-63f6-e74c-cb85a81d0383@dalibo.com
[2] https://postgr.es/m/6acbe570-068e-bd8e-95d5-00c737b865e8@gmail.com
--
Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/
"I'm impressed how quickly you are fixing this obscure issue. I came from
MS SQL and it would be hard for me to put into words how much of a better job
you all are doing on [PostgreSQL]."
Steve Midgley, http://archives.postgresql.org/pgsql-sql/2008-08/msg00000.php