From: | Dave Cramer <pg(at)fastcrypt(dot)com> |
---|---|
To: | Mike Charnoky <noky(at)nextbus(dot)com> |
Cc: | Craig Ringer <ringerc(at)ringerc(dot)id(dot)au>, pgsql-jdbc(at)postgresql(dot)org |
Subject: | Re: Hung JDBC connections |
Date: | 2012-06-11 15:14:04 |
Message-ID: | CADK3HHKHaSzzu__Ouk0XP-2Wnb_dTkLM89zbnumBEdFpja8RMw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
Mike,
It was implemented in the 9_2 code
Dave Cramer
dave.cramer(at)credativ(dot)ca
http://www.credativ.ca
On Mon, Jun 11, 2012 at 11:02 AM, Mike Charnoky <noky(at)nextbus(dot)com> wrote:
>
> On 06/09/2012 11:39 PM, Craig Ringer wrote:
>>
>>
>> Of course, It's not very friendly for the JDBC driver to wait indefinitely
>> without periodically checking and seeing if the connection was progressing,
>> so I'm glad to see that's changed in 9.1.
>>
> I took a look at the 9.1 JDBC driver source code, very enlightening. I see
> that Statement.setQueryTimeout() doesn't actually do anything! The method
> sets a member variable which is never accessed locally or by any subclasses
> or via getQueryTimeout(). There is even the following comment in
> AbstractJdbc2Statement:
> /** Timeout (in seconds) for a query (not used) */
> protected int timeout = 0;
>
> I see that ConnectionFactoryImpl does allow the underlying Socket's
> so_timeout and so_keepalive options to be set using the connection
> parameters string: http://jdbc.postgresql.org/documentation/91/connect.html
> (socketTimeout and tcpKeepAlive). Didn't realize these options existed, I
> will definitely be taking advantage of these.
>
> However, I see these options were available as far back as 8.4. What exactly
> are these driver changes in 9.1 that you mentioned???
>
>
> Mike
>
>
> --
> Sent via pgsql-jdbc mailing list (pgsql-jdbc(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-jdbc
From | Date | Subject | |
---|---|---|---|
Next Message | wbrana | 2012-06-11 15:30:42 | Re: Re: [BUGS] BUG #6684: An I/O error occured while sending to the backend |
Previous Message | Mike Charnoky | 2012-06-11 15:02:08 | Re: Hung JDBC connections |