Search Postgresql Archives

Re: Fwd: libpq: indefinite block on poll during network problems

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Dmitry Samonenko <shreddingwork@xxxxxxxxx> writes:
> So, should I fill a bug report?

[ shrug... ] This is not a bug.  It might be a feature request, but
I doubt that it's a feature anybody would be interested in implementing.
Adding timeouts to libpq would mean adding hard-to-test (and therefore
easy-to-break) logic paths, in service of what seems like a very debatable
design decision.  It's really the business of the network stack to decide
when a TCP connection has been lost, not libpq.  And it's not exactly
clear what recovery action libpq should take if it were to decide the
connection had been lost first.

BTW, you might consider using libpq's nonblock mode to push the waiting
out to the application level, and then you could just decide when you've
waited too long for yourself.

			regards, tom lane



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux