Re: [HACKERS] Proposal for async support in libpq

From: Peter T Mount <psqlhack(at)maidast(dot)demon(dot)co(dot)uk>
To: Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us>
Cc: hackers(at)postgresql(dot)org
Subject: Re: [HACKERS] Proposal for async support in libpq
Date: 1998-04-18 10:34:25
Message-ID: Pine.LNX.3.95.980418112653.7910A-100000@maidast.demon.co.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, 18 Apr 1998, Bruce Momjian wrote:

> In backend/libpq/pqcomm.c, I see pg_sendoob() which sends out-of-band
> data FROM the backend TO the client, but it is not called from anywhere.
>
> This could be a method of signaling that a notification was pending, and
> sending out-of-band data FROm the client TO the backend could be used
> for cancelling a query.
>
> out-of-band data causes a convenient signal to the process on the other
> end, which can easily be used to handle these cases.

Just a quick question: If you have an OOB packet sent to the backend, how
would we handle the case where a row is being sent to the backend, but the
OOB packet comes in the middle of it?

It may sound like a silly question, but I'm thinking if a client is on the
end of a slow network connection, then the packet containing the row could
become fragmented, and the OOB packet could get in the way.

Anyhow, I'm trying to find out how to implement OOB in Java. I know it's
there, as I've seen it in the past. Just can't find it at the moment.

--
Peter T Mount petermount(at)earthling(dot)net or pmount(at)maidast(dot)demon(dot)co(dot)uk
Main Homepage: http://www.demon.co.uk/finder
Work Homepage: http://www.maidstone.gov.uk Work EMail: peter(at)maidstone(dot)gov(dot)uk

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter T Mount 1998-04-18 10:37:07 Re: [HACKERS] lock failed and buffer leak
Previous Message Maarten Boekhold 1998-04-18 10:10:47 Re: [HACKERS] Proposal for async support in libpq