From: | "Vinay S (vinas)" <vinas(at)cisco(dot)com> |
---|---|
To: | Kris Jurka <books(at)ejurka(dot)com>, Kevin Wooten <kdubb(at)me(dot)com> |
Cc: | Dave Cramer <davecramer(at)gmail(dot)com>, List <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: JDBC executeBatch() hangs without error |
Date: | 2013-09-26 18:14:10 |
Message-ID: | 3D2CB312427D204EAC2BCEB9771CB1951E3F51B5@xmb-aln-x01.cisco.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
This worked!
Increased MAX_BUFFERED_QUERIES to a big enough number for the read/write to take place comfortably and the executeBatch() worked.
How can I help with this so somebody else can easily find the answer if they stumble into a similar issue? Can I benchmark for you guys? Run different batchsizes on different OS's? All ears.
Thanks a bunch again!
- Vinay
-----Original Message-----
From: Vinay S (vinas)
Sent: Thursday, September 26, 2013 11:20 PM
To: 'Kris Jurka'; Kevin Wooten
Cc: Dave Cramer; List
Subject: RE: [JDBC] JDBC executeBatch() hangs without error
That sounds about right.
So, I'll try to play around with private static final int MAX_BUFFERED_QUERIES and update you guys.
Thanks a bunch.
- Vinay
-----Original Message-----
From: Kris Jurka [mailto:books(at)ejurka(dot)com]
Sent: Thursday, September 26, 2013 11:18 PM
To: Kevin Wooten
Cc: Vinay S (vinas); Dave Cramer; List
Subject: Re: [JDBC] JDBC executeBatch() hangs without error
On Thu, 26 Sep 2013, Kevin Wooten wrote:
> Could this be related to the note in QueryExecutorImpl.java ~ line 287
> titled "Deadlock Avoidance"?
> If I remember correctly it's specifically related to batched queries
> and synchronous TCP.
Almost certainly. The thing to look at is setting the network buffer sizes to use to large values to avoid the deadlock. The default values are machine dependent which also explains it working or not on different machines. These are unfortunately not documented, but were introduced in this commit:
https://github.com/pgjdbc/pgjdbc/commit/4e7f65b91e95d6249c78de6944f09cd34ef1ae87
Kris Jurka
From | Date | Subject | |
---|---|---|---|
Next Message | Sehrope Sarkuni | 2013-09-28 17:19:08 | Re: [PATCH] New SSL Socket Factory With Certificate Validation |
Previous Message | Vinay S (vinas) | 2013-09-26 17:49:44 | Re: JDBC executeBatch() hangs without error |