Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1W84yv-0006Wl-6f for pgsql-jdbc@arkaria.postgresql.org; Tue, 28 Jan 2014 09:29:21 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1W84yu-0005bE-Ib for pgsql-jdbc@arkaria.postgresql.org; Tue, 28 Jan 2014 09:29:20 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1W84yt-0005b8-SQ for pgsql-jdbc@postgresql.org; Tue, 28 Jan 2014 09:29:19 +0000 Received: from prod2.officenet.no ([195.159.87.246]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1W84yq-0000Il-B5 for pgsql-jdbc@postgresql.org; Tue, 28 Jan 2014 09:29:19 +0000 Received: from localhost ([127.0.0.1] helo=prod2) by prod2.officenet.no with esmtp (Exim 4.76) (envelope-from ) id 1W84yp-0001Fu-Qk for pgsql-jdbc@postgresql.org; Tue, 28 Jan 2014 10:29:15 +0100 Date: Tue, 28 Jan 2014 10:29:15 +0100 (CET) From: Andreas Joseph Krogh To: pgsql-jdbc@postgresql.org Message-ID: In-Reply-To: <52E7769E.2090401@redhat.com> Subject: Re: Will Connection.createBlob be implemented any time soon? MIME-Version: 1.0 X-Mailer: OfficeNet Mail 1.9.0-SNAPSHOT X-Pg-Spam-Score: -2.4 (--) Content-Type: multipart/alternative; boundary="----=_Part_17_1720259234.1390901355762" List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-jdbc Precedence: bulk Sender: pgsql-jdbc-owner@postgresql.org ------=_Part_15_436347729.1390901355752 Content-Type: multipart/related; boundary="----=_Part_16_39626798.1390901355752" ------=_Part_16_39626798.1390901355752 Content-Type: multipart/alternative; boundary="----=_Part_17_1720259234.1390901355762" ------=_Part_17_1720259234.1390901355762 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable P=C3=A5 tirsdag 28. januar 2014 kl. 10:21:34, skrev Florian Weimer < fweimer@redhat.com >: On 01/28/2014 09:09 AM,=20 Andreas Joseph Krogh wrote: > I need streaming yes, that's why I use Blobs. The PostgreSQL wire protocol does not support streaming BYTEA parameters and result data. =C2=A0 Why do you assume I use BYTEA? I use OID for myu b= lobs. =C2=A0 =C2=A0 =C2=A0 Your initial example does not actually use streaming in an essential way, so I'm not sure what you're trying to achieve. =C2=A0= Read it=20 again, it does use streaming. It copies the "is" stream out to the "os" str= eam,=20 backed by the Blob. Using EclipseLink with the pgjdbc-ng driver it works=20 perfectly using Connection.createBlob, streaming etc. I've tried streaming = >=20 200GB stuff with a Blob field in a JPA-object and it works. =C2=A0 What pus= sles me=20 is why the "official" driver doesn't implement createBlob as I thought it= =20 should be a quit common use-case to want to stream large data-chunks in the= db=20 (for tx-purposes). =C2=A0 -- Andreas Joseph Krogh =C2=A0 =C2=A0 =C2=A0 mob: +47 9= 09 56 963 Senior Software Developer / CTO - OfficeNet AS - http://www.officenet.no Public key: http://home.officenet.no/~andreak/public_key.asc =C2=A0 ------=_Part_17_1720259234.1390901355762 Content-Type: text/html;charset=UTF-8 Content-Transfer-Encoding: quoted-printable
P=C3=A5 tirsdag 28. januar 2014 kl. 10:21:34, skrev Florian Weimer <= ;fweimer@redhat.com= >:
On = 01/28/2014 09:09 AM, Andreas Joseph Krogh wrote:

> I need streaming yes, that's why I use Blobs.

The PostgreSQL wire protocol does not support streaming BYTEA parameters and result data.
=C2= =A0
Why= do you assume I use BYTEA? I use OID for myu blobs.
=C2= =A0
=C2= =A0
=C2= =A0 Your initial example does not actually use streaming
in an essential way, so I'm not sure what you're trying to achieve.
=C2=A0
Read it again, it does use streaming. It copies the "is" str= eam out to the "os" stream, backed by the Blob.
Using EclipseLink with the pgjdbc-ng driver it works perfectly using C= onnection.createBlob, streaming etc. I've tried streaming > 200GB stuff = with a Blob field in a JPA-object and it works.
=C2=A0
What pussles me is why the "official" driver doesn't impleme= nt createBlob as I thought it should be a quit common use-case to want to s= tream large data-chunks in the db (for tx-purposes).
=C2=A0
--
Andreas Joseph Krogh <andreak@officenet.no>=C2=A0 =C2=A0 =C2=A0 mob: = +47 909 56 963
Senior Software Developer / CTO - OfficeNet AS - http://www.officenet.no Public key: http://home.officenet.no/~andreak/public_key.asc
=C2=A0
------=_Part_17_1720259234.1390901355762-- ------=_Part_16_39626798.1390901355752-- ------=_Part_15_436347729.1390901355752--