Re: Postgres jdbc bulk insert stuck

From: dmachop <dmachop(at)gmail(dot)com>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Postgres jdbc bulk insert stuck
Date: 2016-05-22 03:38:20
Message-ID: 1463888300214-5904483.post@n5.nabble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

The table doesn't contain any keys, indices, triggers, etc.
This is the first time I create the table. I run a create statement and then
run inserts.

Vitalii Tymchyshyn-2 wrote
> Does it stop on the first batch?

No. In fact, 4 batches are processed and gets stuck at 5th batch. Tried with
different batch count 256, 1000 (Stuck at after processing 1280, 5000 rows
respectively).

Vitalii Tymchyshyn-2 wrote
> Have you got any triggers on the table?

None whatsoever. Just created a table and nothing else.

Vitalii Tymchyshyn-2 wrote
> Are there any notices sent back to the client? There is a certain
> limitation related to client TCP read/write sequencing.

I don't receive notifications. Debugged at a point and this is the dump
where it seems to be stuck for about an hour or more
Thread [BulkDownloader-1] (Suspended)
owns: BufferedOutputStream (id=5108)
owns: QueryExecutorImpl (id=4483)
SocketOutputStream.socketWrite0(FileDescriptor, byte[], int, int) line: not
available [native method] [local variables unavailable]
SocketOutputStream.socketWrite(byte[], int, int) line: 109
SocketOutputStream.write(byte[], int, int) line: 153
BufferedOutputStream.flushBuffer() line: 82
BufferedOutputStream.write(byte[], int, int) line: 121
BufferedOutputStream(FilterOutputStream).write(byte[]) line: 97
PGStream.Send(byte[]) line: 229
QueryExecutorImpl.sendParse(SimpleQuery, SimpleParameterList, boolean) line:
1327
QueryExecutorImpl.sendOneQuery(SimpleQuery, SimpleParameterList, int, int,
int) line: 1629
QueryExecutorImpl.sendQuery(V3Query, V3ParameterList, int, int, int,
QueryExecutorImpl$ErrorTrackingResultHandler, BatchResultHandler) line: 1216
QueryExecutorImpl.execute(Query[], ParameterList[], BatchResultHandler, int,
int, int) line: 351
PgPreparedStatement(PgStatement).executeBatch() line: 1019
DelegatingPreparedStatement(DelegatingStatement).executeBatch() line: 345
DelegatingPreparedStatement(DelegatingStatement).executeBatch() line: 345
QueryRunner.batch(Connection, boolean, String, Object[][]) line: 152
QueryRunner.batch(Connection, String, Object[][]) line: 92
DBUtil.batch(String, Object[][]) line: 141
DBWriter.merge(SalesforceObject) line: 172
...

--
View this message in context: http://postgresql.nabble.com/Postgres-jdbc-bulk-insert-stuck-tp5904350p5904483.html
Sent from the PostgreSQL - jdbc mailing list archive at Nabble.com.

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Vladimir Sitnikov 2016-05-22 06:45:38 Re: Postgres jdbc bulk insert stuck
Previous Message Vitalii Tymchyshyn 2016-05-21 22:17:18 Re: Postgres jdbc bulk insert stuck