pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Craig Ringer <craig@2ndquadrant.com>
To: Dave Cramer <pg@fastcrypt.com>
To: Vitalii Tymchyshyn <vit@tym.im>
Cc: Enrico Olivelli - Diennea <enrico.olivelli@diennea.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: John R Pierce <pierce@hogranch.com>
Cc: PG-JDBC Mailing List <pgsql-jdbc@postgresql.org>
Subject: Re: Disk buffering of resultsets
Date: Tue, 21 Oct 2014 20:48:06 +0800
Message-ID: <54465606.6090602@2ndquadrant.com> (raw)
In-Reply-To: <CADK3HH+offVAUeAq5ROw3_Kg2p9BXT1zEEiNMLgKV_MX2WkVYA@mail.gmail.com>
References: <CAHKhnVUW9hu9ePD9zeVmvkeRjK8VaO9_jVDdqiNPf8=xBkaM1Q@mail.gmail.com>
	<541E7FC3.3000201@2ndquadrant.com>
	<3F6D0B4E-2FA9-42D0-8C2C-DC68E6D0D641@gmail.com>
	<54205F94.9010102@hogranch.com>
	<CAHKhnVX5qxNOCBFXwivt1Mwzdaru9hoG9wCviAKUj9Dcmnu=0w@mail.gmail.com>
	<542091F0.10706@hogranch.com>
	<1321.1411433175@sss.pgh.pa.us>
	<CABWW-d3QW0ywPge0-mVZ1d1WhsGwB5cWy4wOo3CK-sPOdqEKiA@mail.gmail.com>
	<54300AA6.3040309@2ndquadrant.com>
	<CABWW-d0bNau=Ypx2iidbmMeuA8ks75xn=dNv7n4m_XEHz8wJkg@mail.gmail.com>
	<5435F3DA.1060401@2ndquadrant.com>
	<CABWW-d2j6PapSxo29dsG2CP2Somsh8cUjcOX1eXdG=NH7NC0hQ@mail.gmail.com>
	<ADD972C51196844491C410BCD4146DCD60A9BEAA32@dnaexc01.diennea.lan>
	<CABWW-d06uTMsLcLx7YHbxZFu8L=ssJSed3pD0j0rMF3JnzBtTg@mail.gmail.com>
	<CADK3HH+offVAUeAq5ROw3_Kg2p9BXT1zEEiNMLgKV_MX2WkVYA@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-jdbc>

On 10/21/2014 07:06 PM, Dave Cramer wrote:
> Hi Vitalii,
> 
> Thanks for this. I am headed for pgconf, hopefully I will have time to
> look at it on the plane.

Great that you're coming.

I'm still concerned by this patch, particularly the fact that it doesn't
properly use partial result set fetching at the protocol level, or
didn't last time I looked.

I really think it should be restricted to v3 protocol support and use
partial EXECUTE.

I'm generally opposed to the idea of the next query incurring the cost
of fetching remaining results from the prior one, and possibly throwing
an unrelated exception. That's IMO just wrong.

I'm not at all convinced we shouldn't be using server-side portals, and
possibly a client-supplied helper thread pool. I really don't like
hijacking a possibly unrelated thread (that's trying to run the next
statement) to do work deferred by a prior connection.

Instead we should probably:

    WARNING: Discarding unfetched results from prior connection
    HINT: To avoid this warning, explicitly close() the result set or
          fully read it before running a new statement.

or even make it an ERROR.

-- 
 Craig Ringer                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


-- 
Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-jdbc



view thread (37+ messages)  latest in thread

Message-ID: <54465606.6090602@2ndquadrant.com>
Permalink:  ../54465606.6090602@2ndquadrant.com/
Also on:    postgresql.org/message-id/54465606.6090602@2ndquadrant.com

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: craig@2ndquadrant.com, pg@fastcrypt.com, vit@tym.im, enrico.olivelli@diennea.com, tgl@sss.pgh.pa.us, pierce@hogranch.com
  Subject: Re: Disk buffering of resultsets
  In-Reply-To: <54465606.6090602@2ndquadrant.com>
  References: <CAHKhnVUW9hu9ePD9zeVmvkeRjK8VaO9_jVDdqiNPf8=xBkaM1Q@mail.gmail.com> <541E7FC3.3000201@2ndquadrant.com> <3F6D0B4E-2FA9-42D0-8C2C-DC68E6D0D641@gmail.com> <54205F94.9010102@hogranch.com> <CAHKhnVX5qxNOCBFXwivt1Mwzdaru9hoG9wCviAKUj9Dcmnu=0w@mail.gmail.com> <542091F0.10706@hogranch.com> <1321.1411433175@sss.pgh.pa.us> <CABWW-d3QW0ywPge0-mVZ1d1WhsGwB5cWy4wOo3CK-sPOdqEKiA@mail.gmail.com> <54300AA6.3040309@2ndquadrant.com> <CABWW-d0bNau=Ypx2iidbmMeuA8ks75xn=dNv7n4m_XEHz8wJkg@mail.gmail.com> <5435F3DA.1060401@2ndquadrant.com> <CABWW-d2j6PapSxo29dsG2CP2Somsh8cUjcOX1eXdG=NH7NC0hQ@mail.gmail.com> <ADD972C51196844491C410BCD4146DCD60A9BEAA32@dnaexc01.diennea.lan> <CABWW-d06uTMsLcLx7YHbxZFu8L=ssJSed3pD0j0rMF3JnzBtTg@mail.gmail.com> <CADK3HH+offVAUeAq5ROw3_Kg2p9BXT1zEEiNMLgKV_MX2WkVYA@mail.gmail.com> <54465606.6090602@2ndquadrant.com>

* 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