Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WTTyy-0002yd-G7 for pgsql-jdbc@arkaria.postgresql.org; Fri, 28 Mar 2014 10:25:52 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WTTyx-0005Oz-KU for pgsql-jdbc@arkaria.postgresql.org; Fri, 28 Mar 2014 10:25:51 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WTTyv-0005Oq-G9 for pgsql-jdbc@postgresql.org; Fri, 28 Mar 2014 10:25:49 +0000 Received: from nm1-vm8.bullet.mail.ir2.yahoo.com ([212.82.96.79]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WTTyr-0004E6-MU for pgsql-jdbc@postgresql.org; Fri, 28 Mar 2014 10:25:48 +0000 Received: from [212.82.98.54] by nm1.bullet.mail.ir2.yahoo.com with NNFMP; 28 Mar 2014 10:25:43 -0000 Received: from [212.82.98.92] by tm7.bullet.mail.ir2.yahoo.com with NNFMP; 28 Mar 2014 10:25:43 -0000 Received: from [127.0.0.1] by omp1029.mail.ir2.yahoo.com with NNFMP; 28 Mar 2014 10:25:43 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 801067.61875.bm@omp1029.mail.ir2.yahoo.com Received: (qmail 58166 invoked by uid 60001); 28 Mar 2014 10:25:43 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.fr; s=s1024; t=1396002343; bh=hnbzAwQIMibevLCmnZcVfJZAn8N7/VcNYKcny3xpquA=; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:References:Message-ID:Date:From:Reply-To:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=FlcCne4xKqlXkLatiivqFoYS2H6S9aIimIqH5Du6Hi+qOv2RbcDOZkP1delrQVEEulVObd2lJu/EPS2MUvOOAPq135m0fePUS297ywIiW4c5t5JzwNTDtCBpxMns6GqEcGfH+00KFZJAADnCidIDk6U6+07GmhXqSyyqDhMyeH4= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.fr; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:References:Message-ID:Date:From:Reply-To:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=i8Io6jvZr3tGXqf74t8J8ROgvnvtsGmQl6RC5bb7TnTgAjO065oqaomvlginr5Pda5vlJ1y309+7eE+ktHbisLsimf98U50SUQL1sb5UvnuiFC5UeSGXDvIFOU9pu34cNScTr9vslAkgt432QYIguPdV1JIe1FSkcf2tfFbtiTk=; X-YMail-OSG: lDkyqx8VM1mbtacHWJjF8c4RL.T4nASyxhQ9DzJzS22HL6K LZ_9CSpB8wi94LMjMPWEgegj6jllZn2TvL31OwOPzzzj94IWbVJcWw4zIdT1 AOLkZadgzQS9nbtwSW.k0VxGIn5GVTldt6uccSKaeGZ7NB.sfcsXpg4pEYIg 0cUQSWrL4d.tlu5ik5puGfovumLbtblQVBTaBNLnQ9gwxESjGR0_Rsd.0hKu ZlvZJoz4lR5J3oX33SzFxPbz3xQJoyIux9Fiautpb93uyWO.RLTE.D2vPgdW Q7NaWvxJrccBN6pTYAW3LPqDMIeR8zo7cNZXmNV78gMoSNSHD9WaksuKgBE0 tWkZ2hlD0VHgCxRxHh02TWGR4OuMu7pgEkpjnvwbY8Qpz3mtex_fSQaKi6Jg ZeMe5qnvb7DbJ5ii2t5p7UwTL7KhfxY_dm_66QgFDYGfeYZQRuLDstyEEh1A 1JwoecfDmeASErLws2yPtld24Jotpy5wpZMAH4FfHigsCFbAi114AshJ_tSa BKP8sFNOYjjwK.MErLr8e.pnP3jTzlkZhcCtoGy.1nkVb_0GJffcVUcmoUAA mWP16JeMWdVcHjQVFmMY71XNHdkLNXkIpmjBvRcdaxEcHm1X0iPhsDEA- Received: from [193.51.160.62] by web28905.mail.ir2.yahoo.com via HTTP; Fri, 28 Mar 2014 10:25:43 GMT X-Rocket-MIMEInfo: 002.001, VGhhbmsgeW91IHZlcnkgbXVjaCBmb3IgeW91ciBoZWxwIGFuZCBleHBsYW5hdGlvbnMuCgpJbmRlZWQsIHRoZSBMYWNoZXphcidzIHJlY29tbWVuZGF0aW9uwqAgKGpkYmM6cG9zdGdyZXNxbDovL2xvY2FsaG9zdC9kYXRhYmFzZT9wcm90b2NvbFZlcnNpb249MikgcmVzdG9yZXMgdGhlIHNwZWVkOiAxOTA0MTMgbXMgd2l0aCBqZGJjLTkuMy4xMTAxIGFuZCBwb3N0Z3Jlc3FsIDkuMy40LgoKQXMgSSB1c2VkIGJ5dGVhIGFuZCBkdWUgdG8gY2hhbmdlIHNpbmNlIHBvc3RncmVzcWwgOS4wIGZvciBoYW5kbGluZyABMAEBAQE- X-Mailer: YahooMailWebService/0.8.181.645 References: <1395927334.64921.YahooMailNeo@web28904.mail.ir2.yahoo.com> Message-ID: <1396002343.73991.YahooMailNeo@web28905.mail.ir2.yahoo.com> Date: Fri, 28 Mar 2014 10:25:43 +0000 (GMT) From: ChatPristi Reply-To: ChatPristi Subject: Re: Slow performance with 9.3-110x JDBC 4 To: List In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="-1732997280-1994173884-1396002343=:73991" X-Pg-Spam-Score: -1.5 (-) 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 ---1732997280-1994173884-1396002343=:73991 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Thank you very much for your help and explanations.=0A=0AIndeed, the Lachez= ar's recommendation=A0 (jdbc:postgresql://localhost/database?protocolVersio= n=3D2) restores the speed: 190413 ms with jdbc-9.3.1101 and postgresql 9.3.= 4.=0A=0AAs I used bytea and due to change since postgresql 9.0 for handling= them (bytea_output parameter), my programs only work with=A0 jdbc-9.3.1101= (and no longer with jdbc-8.4-703).=0A=0ASo, I must use 9.3.1101. However, = what=A0 does the sentence "I was recommending that for testing purposes onl= y" by Lachezar means ? How to increase performance of server side prepared = statements ?=0A=0A=0A=0A=0A=0ALe Vendredi 28 mars 2014 10h50, Lachezar Dobr= ev a =E9crit :=0A =0A=A0 For the record: I was recomme= nding that for testing purposes only, to check if the reduced performance i= s related to protocol version (I believe there is a significant change it m= ight).=0A=0A=0A=0A=0A2014-03-27 21:52 GMT+02:00 Dave Cramer :=0A=0AI wanted to avoid that recommendation, but since it is out th= ere. protocolVersion reverts to the same protocol as 8.4 uses which does no= t use server side prepared statements=0A>=0A>=0A>And I would expect it to s= peed up, or at least be the same as 8.4.7=0A>=0A>=0A>Dave=0A>=0A>=0A>www.cr= edativ.ca=0A>=0A>=0A>=0A>=0A>On Thu, Mar 27, 2014 at 1:45 PM, Edson Richter= wrote:=0A>=0A>Em 27/03/2014 13:58, Lachezar Dob= rev escreveu:=0A>>=0A>>You might want to do the same tests after adding ?pr= otocolVersion=3D2=0Ato the connection URL. i.e.: jdbc:postgresql://localhos= t/database?protocolVersion=3D2 2014-03-27 15:35 GMT+02:00 ChatPristi : =0A>>>Dear All, I have a java program that does bulk in= sertions (with transactions and=0APreparedStatements) in a postgresql datab= ase. I have a performance divided=0Abetween two and four when using 9.3-110= 0 JDBC4 and 9.3-1101 in comparison=0Awith postgresql-8.4-703 JDBC4 independ= ently of postgresql version. Time(ms) PG 8.4.7 = 9.3.4=0ADriver=0A8.4-703 193390 188379= =0A9.3.1101 349404 344344 Does anybody else= saw such a difference ? What reasons can explain it ? Another point, is th= at the bulk insertions are prerformed by parallel=0Aprocesses and 9.3-110x = JDBC4 drivers appear to scale poorly. Thanks for any help. =0AWhat to expec= t from "protocolVersoin=3D2"?=0A>>Speed up or down?=0A>>=0A>>Edson=0A>>=0A>= >=0A>>-- =0A>>=0A>>=0A>>Edson Carlos Ericksson Richter =0A>>Sistemas para B= ibliotecas, Escolinhas Infantis=0A>>Projetos sob medida para sua empresa = =0A>>Celular: (51) 9318-9766=0A>>(51) 8585-0796 =0A>>"A mente que se abre a= uma nova ideia jamais voltar=E1 ao seu tamanho original"=0A>>- Albert Eins= tein =0A>>=0A> ---1732997280-1994173884-1396002343=:73991 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable
Thank you very much for your help and explanations= .

=
Indeed, the = Lachezar's recommendation  ( jdbc:postgresql://lo= calhost/database?protocolVersion=3D2) restores the speed: 190413 ms with jdbc-9.3.1101 and postgresql 9.3.4.<= /span>

As I used bytea and due to change since = postgresql 9.0 for handling them (bytea_output parameter), my programs only= work with  jdbc-9.3.1101 (and no longer with jdbc-8.4-703).<= /div>

So, I must use 9.3.1101. However, what  do= es the sentence "I was recommending that for testing purposes only" by Lachezar means ? How to increase performance of server side prepar= ed statements ?

<= /span>
<= br>
Le Vendre= di 28 mars 2014 10h50, Lachezar Dobrev <l.dobrev@gmail.com> a =E9crit= :
  For the record: I was recom= mending that for testing purposes only, to check if the reduced performance= is related to protocol version (I believe there is a significant change it= might).
=0A


2014-03-27 21:52 GMT+02:00 Dave Cramer <davecramer@gmail.com= >:
=0A
=
I wanted to avoid that recommendation, but since it is out= there. protocolVersion reverts to the same protocol as 8.4 uses which does= not use server side prepared statements
=0A
And I would expect it to speed up, or at least be the same as 8.4.7=0A=0A

Dave



On Thu, Mar = 27, 2014 at 1:45 PM, Edson Richter <edsonrichter@hotmail.com&g= t; wrote:
=0A=0A=0A
=0A=0A =0A =0A =0A
=0A
Em 27/03/2014 13:58= , Lachezar Dobrev=0A escreveu:
=0A
=0A=
=0A
  You might want to do the same=
 tests after adding ?protocolVersion=3D2=0Ato the connection URL.=0A  i.e.:=
=0A   jdbc:postgresql://localhost/database?protocolVersion=3D2=0A=0A2014-03=
-27 15:35 GMT+02:00 ChatPristi <cchristo_0899@yahoo.fr>:=0A
=0A =0A
Dear All,=0A=0AI have a java program t=
hat does bulk insertions (with transactions and=0APreparedStatements) in a =
postgresql database. I have a performance divided=0Abetween two and four wh=
en using 9.3-1100 JDBC4 and 9.3-1101 in comparison=0Awith postgresql-8.4-70=
3 JDBC4 independently of postgresql version.=0A=0A Time(ms)                =
PG     8.4.7            9.3.4=0ADriver=0A8.4-703                          1=
93390         188379=0A9.3.1101                         349404         3443=
44=0A=0ADoes anybody else saw such a difference ? What reasons can explain =
it ?=0A=0AAnother point, is that the bulk insertions are prerformed by para=
llel=0Aprocesses and 9.3-110x JDBC4 drivers appear to scale poorly.=0A=0ATh=
anks for any help.=0A
=0A
=0A
=0A   =
 
=0A What to expect from "protocolVersoin=3D2"?
=0A Speed up or down?
=0A
=0A Edson
=0A =
=0A
--
=0A =
=0A
=0A = Edson Carlos Ericksson Richter=0A <= br clear=3D"none">=0A Sistemas para Bibliotecas, Escolinhas= Infantis
=0A Projetos sob medida para sua= empresa
=0A
Celular:<= /font>(51) 9318-9766
= =0A (51) 8585-0= 796
=0A = "A mente que se abre a uma nova ideia jamais voltar=E1 ao=0A = seu tamanho original"
=0A - Albert= Einstein=0A
=0A
=0A
=0A
=0A=0A

=0A



---1732997280-1994173884-1396002343=:73991--