Skip site navigation (1) Skip section navigation (2)

Re: Full socket send buffer prevents cancel, timeout

From: "Stephen R(dot) van den Berg" <srb(at)cuci(dot)nl>
To: Michael Fuhr <mike(at)fuhr(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Full socket send buffer prevents cancel, timeout
Date: 2008-10-27 11:59:37
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Michael Fuhr wrote:
>On Sat, Oct 25, 2008 at 12:36:24PM -0400, Tom Lane wrote:
>> The backend can't take it upon itself to interrupt the send, because
>> that would result in loss of protocol message sync, and without
>> knowing how many bytes got sent there's really no way to recover.
>> The only escape from the backend side would be to abort the session ---
>> and even that's a bit problematic since we'd probably try to issue an
>> error message somewhere on the way out, which isn't going to work
>> either if the send buffer is full.

>Yeah, I've already explained those difficulties.  I was hoping that
>discussion might generate ideas on how to deal with them.

What about simply closing the filedescriptor upon discovering a
non-empty sendbuffer upon timeout/querycancel?
           Stephen R. van den Berg.

Teamwork is essential -- it allows you to blame someone else.

In response to


pgsql-hackers by date

Next:From: Tom LaneDate: 2008-10-27 12:02:23
Subject: Re: WIP patch: convert SQL-language functions to return tuplestores
Previous:From: Magnus HaganderDate: 2008-10-27 11:25:28
Subject: Parsing errors in pg_hba.conf

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group