Re: [WIP] pg_ping utility - Mailing list pgsql-hackers

From Christopher Browne
Subject Re: [WIP] pg_ping utility
Date
Msg-id CAFNqd5UnaVCt=+AwHnbcGJDFh27mQUMpT-GTXo0+4hjOMubk_w@mail.gmail.com
Whole thread Raw
In response to Re: [WIP] pg_ping utility  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: [WIP] pg_ping utility  (Phil Sorber <phil@omniti.com>)
List pgsql-hackers
On Tue, Oct 23, 2012 at 6:12 PM, Peter Eisentraut <peter_e@gmx.net> wrote:
> On 10/22/12 11:47 AM, Phil Sorber wrote:
> Also, it seems that about 75% of the patch is connection options processing.  How about
> we get rid of all that and just have them specify a connection string?  It would be a break
> with tradition, but maybe it's time for something new.

I'd be pretty pleased if it had just two ways to get configured:
a) A connection string (which might, in the new order of things, be a
JDBC-like URI), or
b) Environment values drawn in from PGHOST/PGPORT/...

That's pretty much enough configurability, I'd think.

> Functionality:
>
> I'm missing the typical ping functionality to ping continuously.  If we're going to call
> it pg_ping, it ought to do something similar to ping, I think.

Yep, should have equivalents to:-i, an interval between pings,-c, a count-w/-W, a timeout interval

Might be nice to have analogues to:
-D printing timestamp before each line
-q quiets output
-v verbose output (got it, check!)
-V version (got it, check!)
-- 
When confronted by a difficult problem, solve it by reducing it to the
question, "How would the Lone Ranger handle this?"



pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: [WIP] pg_ping utility
Next
From: Phil Sorber
Date:
Subject: Re: [WIP] pg_ping utility