From: Oliver Jowett <oliver@opencloud.com>
To: Kevin Grittner <Kevin.Grittner@wicourts.gov>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Streaming ResultSet
Date: Wed, 20 Jul 2005 11:08:30 +1200
Message-ID: <42DD87EE.8090703@opencloud.com> (raw)
In-Reply-To: <s2dd1ab9.027@gwmta.wicourts.gov>
References: <s2dd1ab9.027@gwmta.wicourts.gov>
Kevin Grittner wrote:
> I'm curious about the reasons that this appoach was taken -- why not
> return the rows as they are retrieved from the server?
The short answer is because to stream on the fly is a much more complex
approach and no-one has stepped forward to implement it.
> (1) It might not be easy to create all of the right conditions for the
> cursored approach to work.
Another solution here is to work on making the cursor support code more
flexible. Again the main reason that this is not done is that no-one has
come up with a robust implementation yet.
> (2) You might think you've met all the conditions for the cursored
> approach and be wrong. The default behavior might kick in and cause an
> OutOfMemoryError.
The same is true with a streaming approach. The driver likes to issue
its own queries internally in many places; if you happen to trip up on
one of those while processing your resultset, boom!
Your best bet to see this implemented is to implement it yourself and
send us a patch. It's a fairly large chunk of work with debatable
benefit, and personally I'd rather spend the time on better cursor
support. (if I *had* time!)
-O
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: oliver@opencloud.com, Kevin.Grittner@wicourts.gov
Subject: Re: Streaming ResultSet
In-Reply-To: <42DD87EE.8090703@opencloud.com>
References: <s2dd1ab9.027@gwmta.wicourts.gov> <42DD87EE.8090703@opencloud.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