pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Meskes <meskes@postgresql.org>
To: Edmund Bacon <edmund.bacon@devstudios.com>
Cc: pgsql-interfaces@postgresql.org
Subject: Re: ECPG connection timeouts
Date: Sun, 23 Mar 2008 18:34:10 +0100
Message-ID: <20080323173410.GB6560@feivel.credativ.de> (raw)
In-Reply-To: <ABAE5512DA3D4E4597C82947769214380138B9CB@devmail.devstudios.local>
References: <ABAE5512DA3D4E4597C82947769214380138B9CB@devmail.devstudios.local>

On Tue, Mar 18, 2008 at 04:47:51PM -0600, Edmund Bacon wrote:
> Is it possible to control how long ECPG takes when trying to connect to
> a database on a remote system (e.g. connect to tcp:postgres//remote/db)

With ecpg calling libpq's connect functions you can just look here for possible options:

http://www.postgresql.org/docs/8.3/interactive/libpq-connect.html

You should use something like
tcp:postgresql://server/database?connect_timeout=14 as database name in
a connect statement. 

However, you will notice that this doesn't work as I just found that the
parser doesn't like the "=14" part. I will fix this in a minute.

Michael
-- 
Michael Meskes
Email: Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org)
ICQ: 179140304, AIM/Yahoo: michaelmeskes, Jabber: meskes@jabber.org
Go VfL Borussia! Go SF 49ers! Use Debian GNU/Linux! Use PostgreSQL!



view thread (3+ messages)  latest in thread

Message-ID: <20080323173410.GB6560@feivel.credativ.de>
Permalink:  ../20080323173410.GB6560@feivel.credativ.de/
Also on:    postgresql.org/message-id/20080323173410.GB6560@feivel.credativ.de

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-interfaces@postgresql.org
  Cc: meskes@postgresql.org, edmund.bacon@devstudios.com
  Subject: Re: ECPG connection timeouts
  In-Reply-To: <20080323173410.GB6560@feivel.credativ.de>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox