Re: RFC: Logging plan of the running query - Mailing list pgsql-hackers

From Andrei Lepikhov
Subject Re: RFC: Logging plan of the running query
Date
Msg-id 11b736a6-a39a-4bac-b359-3daa96e7bc76@gmail.com
Whole thread
In response to Re: RFC: Logging plan of the running query  (torikoshia <torikoshia@oss.nttdata.com>)
Responses Re: RFC: Logging plan of the running query
List pgsql-hackers
Hi,

I began discovering how it works.
Some minor issues after skimming through the code:
1. pg_log_query_plan - This function just sends a signal. There are no
guarantees that actual action will be performed. So, the 'request' word makes
more sense for me.
2. GetCurrentQueryDesc, SetCurrentQueryDesc - need 'extern' in the .h file
3. ExplainPrintPlan, ExplainPrintTriggers - have exact duplicates in the explain.h
4. ExplainStringAssemble() has '0' input for a boolean parameter.
5. ExecSetExecProcNodeRecurse: I don't see PlanState::initPlan. Is this intentional?
6. INJECTION_POINT("log-query-interrupt", ...) - it is called inside a
signal-safe zone. In tests, the caller might do a lot of things in the attached
routine, causing hidden problems later.

-- 
regards, Andrei Lepikhov,
pgEdge



pgsql-hackers by date:

Previous
From: Fujii Masao
Date:
Subject: Re: psql: add tab completion for subscription wal_receiver_timeout
Next
From: Jacob Champion
Date:
Subject: Re: md5_password_warnings for password auth with MD5-encrypted passwords