Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jydMO-0002YX-MA for pgsql-jdbc@arkaria.postgresql.org; Thu, 23 Jul 2020 15:42:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jydMN-00027E-Kx for pgsql-jdbc@arkaria.postgresql.org; Thu, 23 Jul 2020 15:42:15 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jydMN-000277-Dw for pgsql-jdbc@lists.postgresql.org; Thu, 23 Jul 2020 15:42:15 +0000 Received: from sonic312-25.consmr.mail.ir2.yahoo.com ([77.238.178.96]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1jydMF-0002X6-Ce for pgsql-jdbc@lists.postgresql.org; Thu, 23 Jul 2020 15:42:14 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.fr; s=s2048; t=1595518925; bh=z8eO6F31Y1A+cEnCpMPbkmiaLGONQ3rwPFjUEOZpnqY=; h=Date:From:To:Cc:In-Reply-To:References:Subject:From:Subject; b=Z+o4rcuoEkhUtt1sOwrKpOfUtO9Zzr/jiKrUL33lC+nfZ5MyaGVa58OhNmWGO3TEUM81oaY1DdjB2pzmZj5J6cgpfqG2sWBm1+CoeaT5qIUE+vT/14LgA50VclBLq9lQaKkyfJyWmS1RFiFmvbkBw/zSfqRRj/b7Endc4Od//rTV5XX/aRFh5DkHMXBdiiqK3TYb+VzpK5cWR2wQnIVHbH+LHjQ3ajS6zL6hkovLYlOtpzY7CJMGZfoaU6IdsaSe+P6/KNga2q/9def9auDvexTHPsiuS+FIwnG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Om7qxCaYlmcy_nLpPWU9MrnX.jVjrsr6OZ7dJ8u2RffkeBZOtI0rMwk.uLM DJVObEu_2hZ0laHO.LLzeqfNQETsg1AaRaeGM.8BqSn9bym.Bfrx9QpuX61bOCCN.GIu9DyP1LPb 8VuT5YGy7dsK_a3XFhqkcR.O7wcG9jL3Djslq.4XeQ_M9wh7s.bcRNZ4IsLBW1Lv90oj7W1QCVPg oLYduO16KfI0YxPaTxRBTSWzWGB2LVEztaikCRpAoJt.cHDJk4FaTJjfv9V1LggvAilycsjCgLoj fjVRDJnWANvH9HD5_rlaPsU9D6uiit2Yq722yVAyYk4Pt7jpnCuM1LwJkdec0LZk- Received: from sonic.gate.mail.ne1.yahoo.com by sonic312.consmr.mail.ir2.yahoo.com with HTTP; Thu, 23 Jul 2020 15:42:05 +0000 Date: Thu, 23 Jul 2020 15:41:40 +0000 (UTC) From: Christophe combet To: =?UTF-8?Q?Jorge_Sol=C3=B3rzano?= Cc: Dave Cramer , Vladimir Sitnikov , pgsql-jdbc@lists.postgresql.org Message-ID: <1715622817.9240482.1595518900550@mail.yahoo.com> In-Reply-To: References: <347898505.8863312.1595495804718.ref@mail.yahoo.com> <347898505.8863312.1595495804718@mail.yahoo.com> <382025017.8991457.1595502401602@mail.yahoo.com> <928088161.9058165.1595507441236@mail.yahoo.com> <1623541738.9101116.1595510491187@mail.yahoo.com> <1479303015.9175876.1595513983577@mail.yahoo.com> Subject: Re: java.lang.OutOfMemoryError: GC overhead limit exceeded MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_9240481_732949090.1595518900547" X-Mailer: WebService/1.1.16271 YMailNorrin Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.1.2 Safari/605.1.15 Content-Length: 8739 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk ------=_Part_9240481_732949090.1595518900547 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Dear Jorge, Thank you for the explanation and the pointer to the doc. Indeed, the=C2=A0autocommit=3Dfalse + fetchSize combo is working. I did a m= istake when trying the first time as suggested by Vladimir: I used=C2=A0cre= ateStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_READ_ONLY) = which are not the good parameters to be used (bad copy/paste). With createStatement()+fetchSize+autocommit=3Dfalse=C2=A0the exception disa= ppeared. Thank you very much. Le jeudi 23 juillet 2020 =C3=A0 16:31:06 UTC+2, Jorge Sol=C3=B3rzano a =C3=A9crit : =20 =20 The only change that could affect between 42.2.10 (which works based on your first message), and 42.2.11+ is the introduction of the tuple abstraction. The autocommit=3Dfalse + fetchSize combo should help with large tables: https://jdbc.postgresql.org/documentation/head/query.html#fetchsize-example On Thu, Jul 23, 2020 at 4:19 PM Christophe combet wro= te: > > Dear Dave, > > The table definition is: > > CREATE TABLE mytable ( >=C2=A0 =C2=A0 column1 character varying(14) NOT NULL, >=C2=A0 =C2=A0 column2 integer NOT NULL, >=C2=A0 =C2=A0 column3 bytea NOT NULL > ); > > ALTER TABLE ONLY mytable >=C2=A0 =C2=A0 ADD CONSTRAINT mytable_pkey PRIMARY KEY (column1); > > Column column3 contains zipped data (BLOB and toast table). > > The full dump of the table (pg_dump as SQL text) is 24GB. > > Thanks. > Le jeudi 23 juillet 2020 =C3=A0 15:24:54 UTC+2, Dave Cramer a =C3=A9crit : > > > > > On Thu, 23 Jul 2020 at 09:21, Christophe combet wro= te: > > > autocommit=3Dfalse & fetchSize=3D100 or 10000 : same exception. > > 42.2.10 still running. > > > Is there a very large column in there > > > Dave Cramer > www.postgres.rocks > > > > > > Le jeudi 23 juillet 2020 =C3=A0 14:30:56 UTC+2, Christophe combet a =C3=A9crit : > > > > Thank you for pointing the link between auto commit an buffering. > > autocommit=3Dfalse: same exception. > > We try fetchSize. > > Thanks. > Le jeudi 23 juillet 2020 =C3=A0 13:47:14 UTC+2, Vladimir Sitnikov a =C3=A9crit : > > > >can you try switching to autocommit=3Dfalse? > > + you probably need to configure fetchSize as well. > > Vladimir > =20 ------=_Part_9240481_732949090.1595518900547 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Dear Jorge,
=

Thank you for the explanation and the pointer to th= e doc.

Indeed, the autocommi= t=3Dfalse + fetchSize combo is working. I did a mistake when trying the fir= st time as suggested by Vladimir: I used createStatement(Result= Set.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_READ_ONLY) which are not the g= ood parameters to be used (bad copy/paste).

With createSt= atement()+fetchSize+autocommit=3Dfa= lse the exception disappeared.

Thank you very= much.

=20
=20
Le jeudi 23 juillet 2020 =C3=A0 16:31:06 UTC+2, Jorge S= ol=C3=B3rzano <jorsol@gmail.com> a =C3=A9crit :


The only change that could affect bet= ween 42.2.10 (which works based
on your first message), a= nd 42.2.11+ is the introduction of the tuple
abstraction.=

The autocommit=3Dfalse + fetchSize co= mbo should help with large tables:
https://jdbc.postgresql.org/docume= ntation/head/query.html#fetchsize-example


On Thu, Jul 23, 2020 at 4:19 PM Christophe combet <= chrisc_pro@yahoo.fr> wrote:
>
> Dear Dave,
>
>= ; The table definition is:
>
> CR= EATE TABLE mytable (
>    column1 character= varying(14) NOT NULL,
>    column2 integer= NOT NULL,
>    column3 bytea NOT NULL
> );
>
> ALTER T= ABLE ONLY mytable
>    ADD CONSTRAINT mytab= le_pkey PRIMARY KEY (column1);
>
>= ; Column column3 contains zipped data (BLOB and toast table).
>
> The full dump of the table (pg_dump as SQL= text) is 24GB.
>
> Thanks.
> Le jeudi 23 juillet 2020 =C3=A0 15:24:54 UTC+2, Dave Cram= er <davecramer@postgres.rocks> a =C3=A9crit :=
>
>
>
>
> On Thu, 23 Jul 2020 at 09:21, Chri= stophe combet <chrisc_pro@yahoo.fr> wrote:
>
>
> autocommit=3Df= alse & fetchSize=3D100 or 10000 : same exception.
>= ;
> 42.2.10 still running.
>
>
> Is there a very large column in t= here
>
>
> D= ave Cramer
> www.postgres.rocks
>=
>
>
>
>
> Le jeudi 23 juillet 2020 =C3=A0 14= :30:56 UTC+2, Christophe combet <chrisc_pro@yahoo.fr&g= t; a =C3=A9crit :
>
>
>
> Thank you for pointing the link between = auto commit an buffering.
>
> aut= ocommit=3Dfalse: same exception.
>
&= gt; We try fetchSize.
>
> Thanks.=
> Le jeudi 23 juillet 2020 =C3=A0 13:47:14 UTC+2, Vla= dimir Sitnikov <sitnikov.vladimir@gmail.com>= ; a =C3=A9crit :
>
>
> >can you try switching to autocommit=3Dfalse?
>
> + you probably need to configure fetchSize a= s well.
>
> Vladimir
>

------=_Part_9240481_732949090.1595518900547--