top | item 35576415

(no title)

jchmbrln | 2 years ago

This approach is very appealing, but when I put my SRE hat on my first concern is observability. Has anyone implemented tracing for Postgres with a span for each procedure call?

When I put my dev hat on, I want the option of attaching a debugger and adding breakpoints. Anything there?

discuss

order

mike_hearn|2 years ago

With PL/Java you can at least debug stored procedures, because the Java Debug Wire Protocol is a protocol so you can run it over the network. There are instructions for how to attach a debugger in the PL/Java docs.

For debugging SQL remotely, I don't know what's available, if anything. Though if you only use SQL for short things, you can just run it and debug the query interactively I guess.

Most databases have tools for logging query timings and doing auditing. PGAudit is one for Postgres.