pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Oliver Jowett <oliver@opencloud.com>
To: Jesper Thorhauge <jth@conzentrate.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: getBinaryStream and OutOfMemoryException
Date: Wed, 29 Jun 2005 01:06:13 +1200
Message-ID: <42C14B45.8000500@opencloud.com> (raw)
In-Reply-To: <42C10723.5010702@conzentrate.com>
References: <42C10723.5010702@conzentrate.com>

Jesper Thorhauge wrote:
> Looking into the cvs
> checkout from
> 22-05-2005, it really seems to me that getBinaryStream is nothing more
> than a
> getBytes ...??

Correct. The current frontend/backend protocol doesn't really let us do
this differently, at least for bytea columns. It could be made more
memory-efficient (e.g. by using the binary result format rather than the
current text format) but the driver still has to pull the entire column
value across the wire at the time the row is returned.

Another approach would be to write large column values to disk, but
noone's written the code to do that yet; it also has some other problems
such as: what if you are running in an environment where you don't have
access to the disk?

-O



view thread (6+ messages)  latest in thread

Message-ID: <42C14B45.8000500@opencloud.com>
Permalink:  ../42C14B45.8000500@opencloud.com/
Also on:    postgresql.org/message-id/42C14B45.8000500@opencloud.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: oliver@opencloud.com, jth@conzentrate.com
  Subject: Re: getBinaryStream and OutOfMemoryException
  In-Reply-To: <42C14B45.8000500@opencloud.com>
  References: <42C10723.5010702@conzentrate.com> <42C14B45.8000500@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