1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-24 14:22:24 +03:00

Support configurable eventlog application names on Windows

This allows different instances to use the eventlog with different
identifiers, by setting the event_source GUC, similar to how
syslog_ident works.

Original patch by MauMau, heavily modified by Magnus Hagander
This commit is contained in:
Magnus Hagander
2011-10-25 20:02:55 +02:00
parent 90d8e8ff7e
commit d8ea33f2c0
8 changed files with 143 additions and 19 deletions

View File

@ -412,6 +412,7 @@ bool log_executor_stats = false;
bool log_statement_stats = false; /* this is sort of all three
* above together */
bool log_btree_build_stats = false;
char *event_source;
bool check_function_bodies = true;
bool default_with_oids = false;
@ -2819,6 +2820,19 @@ static struct config_string ConfigureNamesString[] =
NULL, assign_syslog_ident, NULL
},
#ifdef WIN32
{
{"event_source", PGC_POSTMASTER, LOGGING_WHERE,
gettext_noop("Sets the application name used to identify"
"PostgreSQL messages in the event log."),
NULL
},
&event_source,
"PostgreSQL",
NULL, NULL, NULL
},
#endif
{
{"TimeZone", PGC_USERSET, CLIENT_CONN_LOCALE,
gettext_noop("Sets the time zone for displaying and interpreting time stamps."),