Re: [PATCH] pg_isready (was: [WIP] pg_ping utility)

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Phil Sorber <phil(at)omniti(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Craig Ringer <craig(at)2ndquadrant(dot)com>, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, Erik Rijkers <er(at)xs4all(dot)nl>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Dimitri Fontaine <dimitri(at)2ndquadrant(dot)fr>, Peter Eisentraut <peter_e(at)gmx(dot)net>, PostgreSQL-development Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCH] pg_isready (was: [WIP] pg_ping utility)
Date: 2013-01-23 18:58:24
Message-ID: 20130123185824.GB23670@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Jan 23, 2013 at 12:27:45PM -0500, Tom Lane wrote:
> Phil Sorber <phil(at)omniti(dot)com> writes:
> > On Wed, Jan 23, 2013 at 11:07 AM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> >> [rhaas pgsql]$ pg_isready -h www.google.com
> >> <grows old, dies>
>
> > Do you think we should have a default timeout, or only have one if
> > specified at the command line?
>
> +1 for default timeout --- if this isn't like "ping" where you are
> expecting to run indefinitely, I can't see that it's a good idea for it
> to sit very long by default, in any circumstance.

FYI, the pg_ctl -w (wait) default is 60 seconds:

from pg_ctl.c:

#define DEFAULT_WAIT 60

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ It's impossible for everything to be true. +

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2013-01-23 19:00:25 Re: pg_ctl idempotent option
Previous Message Bruce Momjian 2013-01-23 18:56:09 Re: pg_ctl idempotent option