Re: PostgreSQL query timeout do not stop JDBC client attemptto read data from the server
От | Dave Cramer |
---|---|
Тема | Re: PostgreSQL query timeout do not stop JDBC client attemptto read data from the server |
Дата | |
Msg-id | CADK3HHJernR3bHbDQ0P3bfLK6hWtsUE1xLnx9L8vMupmnLvZ+w@mail.gmail.com обсуждение исходный текст |
Ответ на | PostgreSQL query timeout do not stop JDBC client attempt to read data from the server (Michał Niklas <michal.niklas@heuthes.pl>) |
Ответы |
Re: PostgreSQL query timeout do not stop JDBC client attemptto read data from the server
|
Список | pgsql-jdbc |
Hi Michal,
This https://www.postgresql.org/message-id/alpine.BSO.2.03.1309261345001.26217%40ejurka.com might be related.
On 24 June 2016 at 06:17, Michał Niklas <michal.niklas@heuthes.pl> wrote:
Hello,
I have a problem in my multithreaded application that uses JDBC
PostgreSQL driver. Sometimes it hangs for many hours with various
queries to various databases. To stop such hangs I set query timeout to
10 minutes, but from my application it doesn't work, it not return after
this time.
jstack of such hung thread looks like:
"srv_thead_160621090411" #1560 prio=5 os_prio=0 tid=0x00007f0d24001800
nid=0x150f runnable [0x00007f0c83ffd000]
java.lang.Thread.State: RUNNABLE
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.socketRead(SocketInputStream.java:116)
at java.net.SocketInputStream.read(SocketInputStream.java:170)
at java.net.SocketInputStream.read(SocketInputStream.java:141)
at
org.postgresql.core.VisibleBufferedInputStream.readMore(VisibleBufferedInputStream.java:143)
at
org.postgresql.core.VisibleBufferedInputStream.ensureBytes(VisibleBufferedInputStream.java:112)
at
org.postgresql.core.VisibleBufferedInputStream.read(VisibleBufferedInputStream.java:70)
at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:283)
at
org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1799)
at
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:200)
- locked <0x00000005dc2f9f88> (a org.postgresql.core.v3.QueryExecutorImpl)
at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:424)
at
org.postgresql.jdbc.PgPreparedStatement.executeWithFlags(PgPreparedStatement.java:161)
at
org.postgresql.jdbc.PgPreparedStatement.executeQuery(PgPreparedStatement.java:114)
В списке pgsql-jdbc по дате отправления: