1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-10 17:42:29 +03:00

Add GUC setting for Australian timezones. Uses new GUC boolean callback

functions to clear date cache.  Allow regression tests to pass when
timezone set.
This commit is contained in:
Bruce Momjian
2001-06-18 16:14:44 +00:00
parent 49ce6fff1d
commit 7dac778561
12 changed files with 78 additions and 54 deletions

View File

@@ -4,7 +4,7 @@
* Support for grand unified configuration scheme, including SET
* command, configuration file, and command line options.
*
* $Header: /cvsroot/pgsql/src/backend/utils/misc/guc.c,v 1.38 2001/06/12 22:54:06 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/misc/guc.c,v 1.39 2001/06/18 16:14:43 momjian Exp $
*
* Copyright 2000 by PostgreSQL Global Development Group
* Written by Peter Eisentraut <peter_e@gmx.net>.
@@ -33,6 +33,7 @@
#include "parser/parse_expr.h"
#include "storage/proc.h"
#include "tcop/tcopprot.h"
#include "utils/datetime.h"
/* XXX these should be in other modules' header files */
@@ -69,6 +70,8 @@ bool Show_btree_build_stats = false;
bool SQL_inheritance = true;
bool Australian_timezones = false;
#ifndef PG_KRB_SRVTAB
#define PG_KRB_SRVTAB ""
#endif
@@ -229,6 +232,9 @@ static struct config_bool
{"sql_inheritance", PGC_USERSET, &SQL_inheritance, true, NULL},
{"australian_timezones", PGC_USERSET, &Australian_timezones,
false, ClearDateCache},
{"fixbtree", PGC_POSTMASTER, &FixBTree, true, NULL},
{NULL, 0, NULL, false, NULL}
@@ -327,8 +333,8 @@ static struct config_real
DEFAULT_CPU_OPERATOR_COST, 0, DBL_MAX, NULL, NULL},
{"geqo_selection_bias", PGC_USERSET, &Geqo_selection_bias,
DEFAULT_GEQO_SELECTION_BIAS, MIN_GEQO_SELECTION_BIAS,
MAX_GEQO_SELECTION_BIAS, NULL, NULL},
DEFAULT_GEQO_SELECTION_BIAS, MIN_GEQO_SELECTION_BIAS,
MAX_GEQO_SELECTION_BIAS, NULL, NULL},
{NULL, 0, NULL, 0.0, 0.0, 0.0, NULL, NULL}
};
@@ -360,8 +366,8 @@ static struct config_string
"", NULL, NULL},
{"wal_sync_method", PGC_SIGHUP, &XLOG_sync_method,
XLOG_sync_method_default,
check_xlog_sync_method, assign_xlog_sync_method},
XLOG_sync_method_default, check_xlog_sync_method,
assign_xlog_sync_method},
{NULL, 0, NULL, NULL, NULL, NULL}
};
@@ -956,6 +962,7 @@ _ShowOption(enum config_type opttype, struct config_generic *record)
case PGC_BOOL:
val = *((struct config_bool *) record)->variable ? "on" : "off";
break;
case PGC_INT:
snprintf(buffer, sizeof(buffer), "%d",
*((struct config_int *) record)->variable);

View File

@@ -84,24 +84,6 @@
#geqo_random_seed = -1 # auto-compute seed
#
# Inheritance
#
#sql_inheritance = true
#
# Deadlock
#
#deadlock_timeout = 1000
#
# Expression Depth Limitation
#
#max_expr_depth = 10000 # min 10
#
# Write-ahead log (WAL)
#
@@ -172,3 +154,13 @@
#trace_lock_oidmin = 16384
#trace_lock_table = 0
#endif
#
# Misc
#
#sql_inheritance = true
#australian_timezones = false
#deadlock_timeout = 1000
#max_expr_depth = 10000 # min 10