pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kiran Kulkarni <kkiran_kulkarni@yahoo.com>
To: Dave Cramer <pg@fastcrypt.com>
Cc: pgsql-jdbc@postgresql.org <pgsql-jdbc@postgresql.org>
Subject: Re: org.postgresql.util.PSQLException: An I/O error occured while sending to the backend
Date: Thu, 28 Jun 2012 09:15:24 -0700 (PDT)
Message-ID: <1340900124.55466.YahooMailNeo@web161403.mail.bf1.yahoo.com> (raw)
In-Reply-To: <CADK3HHJ_DhnYK7=cUP+Fu3bH5uTz-vtB42UyucfVebSreLFzcg@mail.gmail.com>
References: <1340835352.64379.YahooMailNeo@web161405.mail.bf1.yahoo.com>
	<CADK3HHJ_DhnYK7=cUP+Fu3bH5uTz-vtB42UyucfVebSreLFzcg@mail.gmail.com>

Hello David,
We are using postgres 9.0 and JDBC driver is postgresql-8.4-701.jdbc3.jar.
Our app server & DB, both are running on Linux and there is a firewall between app server and DB.

Can upgrading the driver to higher version fix this problem?

I have seen similar posts on the web. Most tell either to reconnect or to try TCP Keep alive.
For my case, hibernate is managing my connections and I would expect hibernate to deal with such scenarios. But since it is not dealing with such issues I would be more comfortable configuring tcp keep alive rather than meddling hibernate managed connections.


Do you know any configuration in hibernate which takes care of such issues? Or else pls give me the steps to configure tcp keep alive.

Regards,
Kiran Kulkarni


________________________________
 From: Dave Cramer <pg@fastcrypt.com>
To: Kiran Kulkarni <kkiran_kulkarni@yahoo.com> 
Cc: "pgsql-jdbc@postgresql.org" <pgsql-jdbc@postgresql.org> 
Sent: Thursday, June 28, 2012 6:08 AM
Subject: Re: [JDBC] org.postgresql.util.PSQLException: An I/O error occured while sending to the backend
 
Can you tell me the version of the driver you are using? Is there a
firewall ? Windows ?

We have had an unusually high number of reports of this lately

Dave Cramer

dave.cramer(at)credativ(dot)ca
http://www.credativ.ca


On Wed, Jun 27, 2012 at 6:15 PM, Kiran Kulkarni
<kkiran_kulkarni@yahoo.com> wrote:
> I am getting this error couple of time in a day. How do I avoid it?
>
> Before making the call, I am checking these below things.
> session.isDirty: false
> session.isOpen: true
> session.isConnected: true
> session.getStatistics: SessionStatistics[entity count=0collection count=0]
>
> connManager.isCurrentlyConnected(): true
> connManager.hasBorrowedConnection(): false
>
> But even after this check i am getting this error. Pls help.
>
> ---------------------------------------------------------------
>
> 2012-06-27 12:48:17,957 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> session.isDirty: false
> 2012-06-27 12:48:17,957 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> session.isOpen: true
> 2012-06-27 12:48:17,957 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> session.isConnected: true
> 2012-06-27 12:48:17,957 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> session.getStatistics: SessionStatistics[entity count=0collection count=0]
> 2012-06-27 12:48:17,957 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> 2012-06-27 12:48:17,957 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> connManager.isCurrentlyConnected(): true
> 2012-06-27 12:48:17,957 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> connManager.hasBorrowedConnection(): false
> 2012-06-27 12:48:17,957 DEBUG [org.hibernate.jdbc.ConnectionManager]
> (TimerForFileReading) opening JDBC connection
> 2012-06-27 12:48:17,957 DEBUG [org.hibernate.jdbc.ConnectionManager]
> (TimerForFileReading) opening JDBC connection
> 2012-06-27 12:48:17,957 TRACE
> [org.hibernate.connection.DriverManagerConnectionProvider]
> (TimerForFileReading) total checked-out connections: 0
> 2012-06-27 12:48:17,957 TRACE
> [org.hibernate.connection.DriverManagerConnectionProvider]
> (TimerForFileReading) total checked-out connections: 0
> 2012-06-27 12:48:17,958 TRACE
> [org.hibernate.connection.DriverManagerConnectionProvider]
> (TimerForFileReading) using pooled JDBC connection, pool size: 0
> 2012-06-27 12:48:17,958 TRACE
> [org.hibernate.connection.DriverManagerConnectionProvider]
> (TimerForFileReading) using pooled JDBC connection, pool size: 0
> 2012-06-27 12:48:17,958 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> connManager.getConnection(): org.postgresql.jdbc3.Jdbc3Connection@57005f31
> 2012-06-27 12:48:17,958 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> conn.isClosed(): false
> 2012-06-27 12:48:17,958 DEBUG [org.hibernate.transaction.JDBCTransaction]
> (TimerForFileReading) begin
> 2012-06-27 12:48:17,958 DEBUG [org.hibernate.transaction.JDBCTransaction]
> (TimerForFileReading) begin
> 2012-06-27 12:48:17,958 DEBUG [org.hibernate.transaction.JDBCTransaction]
> (TimerForFileReading) current autocommit status: false
> 2012-06-27 12:48:17,958 DEBUG [org.hibernate.transaction.JDBCTransaction]
> (TimerForFileReading) current autocommit status: false
> 2012-06-27 12:48:17,958 TRACE [org.hibernate.jdbc.JDBCContext]
> (TimerForFileReading) after transaction begin
> 2012-06-27 12:48:17,958 TRACE [org.hibernate.jdbc.JDBCContext]
> (TimerForFileReading) after transaction begin
> 2012-06-27 12:48:17,958 TRACE [org.hibernate.engine.query.QueryPlanCache]
> (TimerForFileReading) located native-sql query plan in cache (select
> count(*) from bbbb_deployment_location)
> 2012-06-27 12:48:17,958 TRACE [org.hibernate.engine.query.QueryPlanCache]
> (TimerForFileReading) located native-sql query plan in cache (select
> count(*) from bbbb_deployment_location)
> 2012-06-27 12:48:17,958 TRACE [org.hibernate.impl.SessionImpl]
> (TimerForFileReading) SQL query: select count(*) from
> bbbb_deployment_location
> 2012-06-27 12:48:17,958 TRACE [org.hibernate.impl.SessionImpl]
> (TimerForFileReading) SQL query: select count(*) from
> bbbb_deployment_location
> 2012-06-27 12:48:17,958 DEBUG [org.hibernate.jdbc.AbstractBatcher]
> (TimerForFileReading) about to open PreparedStatement (open
> PreparedStatements: 0, globally: 0)
> 2012-06-27 12:48:17,958 DEBUG [org.hibernate.jdbc.AbstractBatcher]
> (TimerForFileReading) about to open PreparedStatement (open
> PreparedStatements: 0, globally: 0)
> 2012-06-27 12:48:17,958 DEBUG [org.hibernate.SQL] (TimerForFileReading)
> select count(*) from bbbb_deployment_location
> 2012-06-27 12:48:17,958 DEBUG [org.hibernate.SQL] (TimerForFileReading)
> select count(*) from bbbb_deployment_location
> 2012-06-27 12:48:17,958 TRACE [org.hibernate.jdbc.AbstractBatcher]
> (TimerForFileReading) preparing statement
> 2012-06-27 12:48:17,958 TRACE [org.hibernate.jdbc.AbstractBatcher]
> (TimerForFileReading) preparing statement
> 2012-06-27 12:48:17,959 INFO  [STDOUT] (TimerForFileReading) 12:48:17.958
> (2) simple execute,
> handler=org.postgresql.jdbc2.AbstractJdbc2Statement$StatementResultHandler@6b443d9,
> maxRows=0, fetchSize=0, flags=1
> 2012-06-27 12:48:17,959 INFO  [STDOUT] (TimerForFileReading) 12:48:17.959
> (2)  FE=> Bind(stmt=S_1,portal=null)
> 2012-06-27 12:48:17,959 INFO  [STDOUT] (TimerForFileReading) 12:48:17.959
> (2)  FE=> Execute(portal=null,limit=0)
> 2012-06-27 12:48:17,959 INFO  [STDOUT] (TimerForFileReading) 12:48:17.959
> (2)  FE=> Parse(stmt=null,query="select count(*) from
> bbbb_deployment_location",oids={})
> 2012-06-27 12:48:17,959 INFO  [STDOUT] (TimerForFileReading) 12:48:17.959
> (2)  FE=> Bind(stmt=null,portal=null)
> 2012-06-27 12:48:17,959 INFO  [STDOUT] (TimerForFileReading) 12:48:17.959
> (2)  FE=> Describe(portal=null)
> 2012-06-27 12:48:17,959 INFO  [STDOUT] (TimerForFileReading) 12:48:17.959
> (2)  FE=> Execute(portal=null,limit=0)
> 2012-06-27 12:48:17,959 INFO  [STDOUT] (TimerForFileReading) 12:48:17.959
> (2)  FE=> Sync
> 2012-06-27 13:03:43,626 INFO  [STDOUT] (TimerForFileReading) 13:03:43.626
> (2)  FE=> Terminate
> 2012-06-27 13:03:43,626 INFO  [STDOUT] (TimerForFileReading) 13:03:43.626
> (2) Discarding IOException on close:
> 2012-06-27 13:03:43,626 INFO  [STDOUT] (TimerForFileReading)
> java.net.SocketException: Broken pipe
> 2012-06-27 13:03:43,626 INFO  [STDOUT] (TimerForFileReading) at
> java.net.SocketOutputStream.socketWrite0(Native Method)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> java.net.SocketOutputStream.write(SocketOutputStream.java:136)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:65)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> java.io.BufferedOutputStream.flush(BufferedOutputStream.java:123)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.core.PGStream.flush(PGStream.java:508)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.core.v3.ProtocolConnectionImpl.close(ProtocolConnectionImpl.java:137)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:282)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:479)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:367)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:271)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:209)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.getResultSet(Loader.java:1811)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.doQuery(Loader.java:696)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:258)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.doList(Loader.java:2233)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2130)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.list(Loader.java:2125)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:312)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1724)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:165)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:175)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.testSession(RdbConnectionFactory.java:153)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.getSession(RdbConnectionFactory.java:100)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> com.aaaa.bbbb.scheduler.TimerForFileReading.updateDB(TimerForFileReading.java:103)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> com.aaaa.bbbb.scheduler.TimerForFileReading$1.run(TimerForFileReading.java:91)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> java.util.TimerThread.mainLoop(Timer.java:512)
> 2012-06-27 13:03:43,627 INFO  [STDOUT] (TimerForFileReading) at
> java.util.TimerThread.run(Timer.java:462)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading)
> org.postgresql.util.PSQLException: An I/O error occured while sending to the
> backend.
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:283)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:479)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:367)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:271)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:209)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.getResultSet(Loader.java:1811)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.doQuery(Loader.java:696)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:258)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.doList(Loader.java:2233)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2130)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.Loader.list(Loader.java:2125)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:312)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1724)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:165)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:175)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.testSession(RdbConnectionFactory.java:153)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.getSession(RdbConnectionFactory.java:100)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> com.aaaa.bbbb.scheduler.TimerForFileReading.updateDB(TimerForFileReading.java:103)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> com.aaaa.bbbb.scheduler.TimerForFileReading$1.run(TimerForFileReading.java:91)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> java.util.TimerThread.mainLoop(Timer.java:512)
> 2012-06-27 13:03:43,628 INFO  [STDOUT] (TimerForFileReading) at
> java.util.TimerThread.run(Timer.java:462)
> 2012-06-27 13:03:43,629 INFO  [STDOUT] (TimerForFileReading) SQLException:
> SQLState(08006)
> 2012-06-27 13:03:43,629 DEBUG [org.hibernate.jdbc.AbstractBatcher]
> (TimerForFileReading) about to close PreparedStatement (open
> PreparedStatements: 1, globally: 1)
> 2012-06-27 13:03:43,629 DEBUG [org.hibernate.jdbc.AbstractBatcher]
> (TimerForFileReading) about to close PreparedStatement (open
> PreparedStatements: 1, globally: 1)
> 2012-06-27 13:03:43,629 TRACE [org.hibernate.jdbc.AbstractBatcher]
> (TimerForFileReading) closing statement
> 2012-06-27 13:03:43,629 TRACE [org.hibernate.jdbc.AbstractBatcher]
> (TimerForFileReading) closing statement
> 2012-06-27 13:03:43,629 DEBUG [org.hibernate.util.JDBCExceptionReporter]
> (TimerForFileReading) could not execute query [select count(*) from
> bbbb_deployment_location]
> org.postgresql.util.PSQLException: An I/O error occured while sending to the
> backend.
> at
> org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:283)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:479)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:367)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:271)
> at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:209)
> at org.hibernate.loader.Loader.getResultSet(Loader.java:1811)
> at org.hibernate.loader.Loader.doQuery(Loader.java:696)
> at
> org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:258)
> at org.hibernate.loader.Loader.doList(Loader.java:2233)
> at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2130)
> at org.hibernate.loader.Loader.list(Loader.java:2125)
> at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:312)
> at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1724)
> at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:165)
> at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:175)
> at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.testSession(RdbConnectionFactory.java:153)
> at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.getSession(RdbConnectionFactory.java:100)
> at
> com.aaaa.bbbb.scheduler.TimerForFileReading.updateDB(TimerForFileReading.java:103)
> at
> com.aaaa.bbbb.scheduler.TimerForFileReading$1.run(TimerForFileReading.java:91)
> at java.util.TimerThread.mainLoop(Timer.java:512)
> at java.util.TimerThread.run(Timer.java:462)
> Caused by: java.net.SocketException: Connection timed out
> at java.net.SocketInputStream.socketRead0(Native Method)
> at java.net.SocketInputStream.read(SocketInputStream.java:129)
> at
> org.postgresql.core.VisibleBufferedInputStream.readMore(VisibleBufferedInputStream.java:135)
> at
> org.postgresql.core.VisibleBufferedInputStream.ensureBytes(VisibleBufferedInputStream.java:104)
> at
> org.postgresql.core.VisibleBufferedInputStream.read(VisibleBufferedInputStream.java:73)
> at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:259)
> at
> org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1620)
> at
> org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:257)
> ... 20 more
> 2012-06-27 13:03:43,629 DEBUG [org.hibernate.util.JDBCExceptionReporter]
> (TimerForFileReading) could not execute query [select count(*) from
> bbbb_deployment_location]
> org.postgresql.util.PSQLException: An I/O error occured while sending to the
> backend.
> at
> org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:283)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:479)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:367)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:271)
> at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:209)
> at org.hibernate.loader.Loader.getResultSet(Loader.java:1811)
> at org.hibernate.loader.Loader.doQuery(Loader.java:696)
> at
> org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:258)
> at org.hibernate.loader.Loader.doList(Loader.java:2233)
> at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2130)
> at org.hibernate.loader.Loader.list(Loader.java:2125)
> at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:312)
> at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1724)
> at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:165)
> at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:175)
> at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.testSession(RdbConnectionFactory.java:153)
> at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.getSession(RdbConnectionFactory.java:100)
> at
> com.aaaa.bbbb.scheduler.TimerForFileReading.updateDB(TimerForFileReading.java:103)
> at
> com.aaaa.bbbb.scheduler.TimerForFileReading$1.run(TimerForFileReading.java:91)
> at java.util.TimerThread.mainLoop(Timer.java:512)
> at java.util.TimerThread.run(Timer.java:462)
> Caused by: java.net.SocketException: Connection timed out
> at java.net.SocketInputStream.socketRead0(Native Method)
> at java.net.SocketInputStream.read(SocketInputStream.java:129)
> at
> org.postgresql.core.VisibleBufferedInputStream.readMore(VisibleBufferedInputStream.java:135)
> at
> org.postgresql.core.VisibleBufferedInputStream.ensureBytes(VisibleBufferedInputStream.java:104)
> at
> org.postgresql.core.VisibleBufferedInputStream.read(VisibleBufferedInputStream.java:73)
> at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:259)
> at
> org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1620)
> at
> org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:257)
> ... 20 more
> 2012-06-27 13:03:43,629 WARN  [org.hibernate.util.JDBCExceptionReporter]
> (TimerForFileReading) SQL Error: 0, SQLState: 08006
> 2012-06-27 13:03:43,629 WARN  [org.hibernate.util.JDBCExceptionReporter]
> (TimerForFileReading) SQL Error: 0, SQLState: 08006
> 2012-06-27 13:03:43,629 ERROR [org.hibernate.util.JDBCExceptionReporter]
> (TimerForFileReading) An I/O error occured while sending to the backend.
> 2012-06-27 13:03:43,629 ERROR [org.hibernate.util.JDBCExceptionReporter]
> (TimerForFileReading) An I/O error occured while sending to the backend.
> 2012-06-27 13:03:43,629 TRACE
> [com.aaaa.bbbb.dbconnection.RdbConnectionFactory] (TimerForFileReading)
> org.hibernate.exception.JDBCConnectionException: could not execute query
> at
> org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:97)
> at
> org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)
> at org.hibernate.loader.Loader.doList(Loader.java:2236)
> at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2130)
> at org.hibernate.loader.Loader.list(Loader.java:2125)
> at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:312)
> at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1724)
> at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:165)
> at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:175)
> at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.testSession(RdbConnectionFactory.java:153)
> at
> com.aaaa.bbbb.dbconnection.RdbConnectionFactory.getSession(RdbConnectionFactory.java:100)
> at
> com.aaaa.bbbb.scheduler.TimerForFileReading.updateDB(TimerForFileReading.java:103)
> at
> com.aaaa.bbbb.scheduler.TimerForFileReading$1.run(TimerForFileReading.java:91)
> at java.util.TimerThread.mainLoop(Timer.java:512)
> at java.util.TimerThread.run(Timer.java:462)
> Caused by: org.postgresql.util.PSQLException: An I/O error occured while
> sending to the backend.
> at
> org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:283)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:479)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:367)
> at
> org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:271)
> at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:209)
> at org.hibernate.loader.Loader.getResultSet(Loader.java:1811)
> at org.hibernate.loader.Loader.doQuery(Loader.java:696)
> at
> org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:258)
> at org.hibernate.loader.Loader.doList(Loader.java:2233)
> ... 12 more
> Caused by: java.net.SocketException: Connection timed out
> at java.net.SocketInputStream.socketRead0(Native Method)
> at java.net.SocketInputStream.read(SocketInputStream.java:129)
> at
> org.postgresql.core.VisibleBufferedInputStream.readMore(VisibleBufferedInputStream.java:135)
> at
> org.postgresql.core.VisibleBufferedInputStream.ensureBytes(VisibleBufferedInputStream.java:104)
> at
> org.postgresql.core.VisibleBufferedInputStream.read(VisibleBufferedInputStream.java:73)
> at org.postgresql.core.PGStream.ReceiveChar(PGStream.java:259)
> at
> org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1620)
> at
> org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:257)
> ... 20 more
>

view thread (19+ messages)  latest in thread

Message-ID: <1340900124.55466.YahooMailNeo@web161403.mail.bf1.yahoo.com>
Permalink:  ../1340900124.55466.YahooMailNeo@web161403.mail.bf1.yahoo.com/
Also on:    postgresql.org/message-id/1340900124.55466.YahooMailNeo@web161403.mail.bf1.yahoo.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: kkiran_kulkarni@yahoo.com, pg@fastcrypt.com
  Subject: Re: org.postgresql.util.PSQLException: An I/O error occured while sending to the backend
  In-Reply-To: <1340900124.55466.YahooMailNeo@web161403.mail.bf1.yahoo.com>
  References: <1340835352.64379.YahooMailNeo@web161405.mail.bf1.yahoo.com> <CADK3HHJ_DhnYK7=cUP+Fu3bH5uTz-vtB42UyucfVebSreLFzcg@mail.gmail.com> <1340900124.55466.YahooMailNeo@web161403.mail.bf1.yahoo.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox