On Fri, 2005-09-16 at 20:48 -0400, Bruce Momjian wrote: > We can go three ways. We can add a boolean GUC to control printing of > the query during a timeout, but that seems like overkill. We can add a > new level for log_min_error_statement that is just above error, but that > seems confusing. I think the right solution would be to allow > log_min_duration_statement to work for canceled queries. Right now, > log_min_duration_statement doesn't work for canceled queries because the > query never completes to give a final duration and hit the test code. > Should that be fixed now or added to the TODO list?
The last one seems the right way to go. So, reformat the message at statement_timeout, so that the log looks exactly like log_min_duration_statement: e.g. LOG: statement_timeout has been activated to cancel statement LOG: duration 1625652ms statement SELECT * from bigOne LOG: query has been cancelled by user action Perhaps we should change the message from kill() to be "statement" rather than "query" also... I'd vote fix now, but I guess that seems to be becoming a regular viewpoint from me. Best Regards, Simon Riggs ---------------------------(end of broadcast)--------------------------- TIP 2: Don't 'kill -9' the postmaster