From: Jesper Thorhauge <jth@conzentrate.com>
To: pgsql-jdbc@postgresql.org
Subject: Re: getBinaryStream and OutOfMemoryException
Date: Tue, 28 Jun 2005 15:13:14 +0200
Message-ID: <42C14CEA.4020704@conzentrate.com> (raw)
In-Reply-To: <42C14B45.8000500@opencloud.com>
References: <42C10723.5010702@conzentrate.com>
<42C14B45.8000500@opencloud.com>
Okay, thanks alot for the quick answer! I was wondering, do you know how
much more efficient it could be done using the binary format you are
mentioning? I'm especially interested in decreasing the amount of memory
used to get large bytea values...
/Jesper
Oliver Jowett wrote:
>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
>
>
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: jth@conzentrate.com
Subject: Re: getBinaryStream and OutOfMemoryException
In-Reply-To: <42C14CEA.4020704@conzentrate.com>
References: <42C10723.5010702@conzentrate.com> <42C14B45.8000500@opencloud.com> <42C14CEA.4020704@conzentrate.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