Re: POC: Extension for adding distributed tracing - pg_tracing - Mailing list pgsql-hackers

From Nikita Malakhov
Subject Re: POC: Extension for adding distributed tracing - pg_tracing
Date
Msg-id CAN-LCVPt=ayjSejTKjzMc-Ncte80k=u+KsgO31pOtK28dh=Ofw@mail.gmail.com
Whole thread Raw
In response to Re: POC: Extension for adding distributed tracing - pg_tracing  (Anthonin Bonnefoy <anthonin.bonnefoy@datadoghq.com>)
Responses Re: POC: Extension for adding distributed tracing - pg_tracing
List pgsql-hackers
Hi!

What do you think about using INSTR_TIME_SET_CURRENT, INSTR_TIME_SUBTRACT and INSTR_TIME_GET_MILLISEC
macros for timing calculations?

Also, have you thought about a way to trace existing (running) queries without directly instrumenting them? It would
be much more usable for maintenance and support personnel, because in production environments you rarely could
change query text directly. For the current state the most simple solution is switch tracing on and off by calling SQL
function, and possibly switch tracing for prepared statement the same way, but not for any random query.

I'll check the patch for the race conditions.

--
Regards,
Nikita Malakhov
Postgres Professional
The Russian Postgres Company

pgsql-hackers by date:

Previous
From: Alexander Lakhin
Date:
Subject: Re: Postgres v15 windows bincheck regression test failures
Next
From: Ashutosh Bapat
Date:
Subject: Re: Memory consumed by child SpecialJoinInfo in partitionwise join planning