Lists: | pgsql-committerspgsql-hackers |
---|
From: | tgl(at)svr1(dot)postgresql(dot)org (Tom Lane) |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql-server: Add code to identify_system_timezone() to try all zones in |
Date: | 2004-05-25 18:08:59 |
Message-ID: | 20040525180859.6C711D1B349@svr1.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
Log Message:
-----------
Add code to identify_system_timezone() to try all zones in the zic
database, not just ones that we cons up POSIX names for. This looks
grim but it seems to take less than a second even on a relatively slow
machine, and since it only happens once during postmaster startup, that
seems acceptable.
Modified Files:
--------------
pgsql-server/src/timezone:
pgtz.c (r1.14 -> r1.15)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/timezone/pgtz.c.diff?r1=1.14&r2=1.15)
From: | Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [COMMITTERS] pgsql-server: Add code to identify_system_timezone() to try all zones in |
Date: | 2004-05-26 03:09:52 |
Message-ID: | 20040526030952.GA24543@dcc.uchile.cl |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
On Tue, May 25, 2004 at 03:08:59PM -0300, Tom Lane wrote:
> Add code to identify_system_timezone() to try all zones in the zic
> database, not just ones that we cons up POSIX names for. This looks
> grim but it seems to take less than a second even on a relatively slow
> machine, and since it only happens once during postmaster startup, that
> seems acceptable.
Is it possible to execute this at initdb time to set the default
timezone in postgresql.conf? The user could get a message about what
timezone was selected, and be offered a --command-line-switch to select
a specific one.
Just an idea ...
--
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"Ninguna manada de bestias tiene una voz tan horrible como la humana" (Orual)
From: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [COMMITTERS] pgsql-server: Add code to identify_system_timezone() |
Date: | 2004-05-26 03:42:04 |
Message-ID: | 200405260342.i4Q3g4E14231@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-committers pgsql-hackers |
Alvaro Herrera wrote:
> On Tue, May 25, 2004 at 03:08:59PM -0300, Tom Lane wrote:
>
> > Add code to identify_system_timezone() to try all zones in the zic
> > database, not just ones that we cons up POSIX names for. This looks
> > grim but it seems to take less than a second even on a relatively slow
> > machine, and since it only happens once during postmaster startup, that
> > seems acceptable.
>
> Is it possible to execute this at initdb time to set the default
> timezone in postgresql.conf? The user could get a message about what
> timezone was selected, and be offered a --command-line-switch to select
> a specific one.
>
> Just an idea ...
But if they change the OS timezone, we need to track that on postmaster
restart.
--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073