1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-02 04:21:28 +03:00

Code review for log_lock_waits patch. Don't try to issue log messages from

within a signal handler (this might be safe given the relatively narrow code
range in which the interrupt is enabled, but it seems awfully risky); do issue
more informative log messages that tell what is being waited for and the exact
length of the wait; minor other code cleanup.  Greg Stark and Tom Lane
This commit is contained in:
Tom Lane
2007-06-19 20:13:22 +00:00
parent 4c310eca2e
commit 6e07228728
7 changed files with 229 additions and 155 deletions

View File

@@ -10,7 +10,7 @@
* Written by Peter Eisentraut <peter_e@gmx.net>.
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/utils/misc/guc.c,v 1.398 2007/06/18 10:02:57 mha Exp $
* $PostgreSQL: pgsql/src/backend/utils/misc/guc.c,v 1.399 2007/06/19 20:13:22 tgl Exp $
*
*--------------------------------------------------------------------
*/
@@ -825,13 +825,14 @@ static struct config_bool ConfigureNamesBool[] =
#endif
{
{"log_lock_waits", PGC_SIGHUP, LOGGING_WHAT,
gettext_noop("Logs long lock wait events."),
{"log_lock_waits", PGC_SUSET, LOGGING_WHAT,
gettext_noop("Logs long lock waits."),
NULL
},
&log_lock_waits,
false, NULL, NULL
},
{
{"log_hostname", PGC_SIGHUP, LOGGING_WHAT,
gettext_noop("Logs the host name in the connection logs."),