pg.ddx.io pgsql-jdbc@postgresql.org mailing list archive
help / color / mirror / Atom feedIndexOutOfBoundsException in org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1720)
2+ messages / 2 participants
[nested] [flat]
* IndexOutOfBoundsException in org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1720)
@ 2012-02-28 16:14 Jan Torben Heuer <mail@jtheuer.de>
2012-02-28 19:28 ` Re: IndexOutOfBoundsException in org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1720) Maciek Sakrejda <msakrejda@truviso.com>
0 siblings, 1 reply; 2+ messages in thread
From: Jan Torben Heuer @ 2012-02-28 16:14 UTC (permalink / raw)
To: pgsql-jdbc
Hi, I noticed a strange Exception on my test server using
postgresql-9.0-801.jdbc4 in this code fragment:
QueryExecutorImpl.java:1720 (pendingBindQueue#get(int))
----------
case '2': // Bind Complete (response to Bind)
pgStream.ReceiveInteger4(); // len, discarded
Portal boundPortal =
(Portal)pendingBindQueue.get(bindIndex++);
if (logger.logDebug())
logger.debug(" <=BE BindComplete [" + boundPortal +
"]");
registerOpenPortal(boundPortal);
break;
----------
java.lang.IndexOutOfBoundsException: Index: 1, Size: 1
at java.util.ArrayList.RangeCheck(ArrayList.java:547)
at java.util.ArrayList.get(ArrayList.java:322)
at
org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1720)
at
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:257)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:500)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:374)
at
org.postgresql.jdbc2.AbstractJdbc2Connection.execSQLQuery(AbstractJdbc2Connection.java:244)
at
org.postgresql.jdbc2.AbstractJdbc2Connection.execSQLQuery(AbstractJdbc2Connection.java:236)
at
org.postgresql.jdbc2.AbstractJdbc2Connection.getTransactionIsolation(AbstractJdbc2Connection.java:760)
at
com.jolbox.bonecp.ConnectionHandle.getTransactionIsolation(ConnectionHandle.java:633)
at
org.datanucleus.store.rdbms.ConnectionFactoryImpl$ManagedConnectionImpl.getConnection(ConnectionFactoryImpl.java:383)
at
org.datanucleus.store.rdbms.ConnectionFactoryImpl$ManagedConnectionImpl.getXAResource(ConnectionFactoryImpl.java:313)
at
org.datanucleus.store.connection.ConnectionManagerImpl.enlistResource(ConnectionManagerImpl.java:389)
at
org.datanucleus.store.connection.ConnectionManagerImpl.allocateConnection(ConnectionManagerImpl.java:252)
at
org.datanucleus.store.connection.AbstractConnectionFactory.getConnection(AbstractConnectionFactory.java:60)
at
org.datanucleus.store.AbstractStoreManager.getConnection(AbstractStoreManager.java:441)
at
org.datanucleus.store.AbstractStoreManager.getConnection(AbstractStoreManager.java:410)
at
org.datanucleus.store.rdbms.query.JDOQLQuery.performExecute(JDOQLQuery.java:595)
at org.datanucleus.store.query.Query.executeQuery(Query.java:1789)
at
org.datanucleus.store.query.Query.executeWithArray(Query.java:1665)
at
org.datanucleus.api.jdo.JDOQuery.executeWithArray(JDOQuery.java:312)
I haven't manged to reproduce this issue on my dev machine. But can someone
give me a hint what happens here? What is a Portal and what does it mean if
an IndexOutOfBounds Exception occurs here?
Thanks,
Jan
--
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: IndexOutOfBoundsException in org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1720)
2012-02-28 16:14 IndexOutOfBoundsException in org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1720) Jan Torben Heuer <mail@jtheuer.de>
@ 2012-02-28 19:28 ` Maciek Sakrejda <msakrejda@truviso.com>
0 siblings, 0 replies; 2+ messages in thread
From: Maciek Sakrejda @ 2012-02-28 19:28 UTC (permalink / raw)
To: Jan Torben Heuer <mail@jtheuer.de>; +Cc: pgsql-jdbc
> I haven't manged to reproduce this issue on my dev machine. But can someone
> give me a hint what happens here? What is a Portal and what does it mean if
> an IndexOutOfBounds Exception occurs here?
Have you reproduced it on the test machine? A portal is a concept
describing the protocol-level construct to get data from a specific
invocation of a prepared statement. From a quick glance at the code,
what you're seeing here shouldn't happen...
Are you perhaps using the same Connection object from multiple
threads? It is ostensibly supported (
http://jdbc.postgresql.org/documentation/head/thread.html ), but I
wonder if this is what's causing issues. E.g., I haven't worked out
the details, but I think a sequence where two threads send independent
Binds concurrently could cause this.
---
Maciek Sakrejda | System Architect | Truviso
1065 E. Hillsdale Blvd., Suite 215
Foster City, CA 94404
(650) 242-3500 Main
www.truviso.com
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2012-02-28 19:28 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2012-02-28 16:14 IndexOutOfBoundsException in org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1720) Jan Torben Heuer <mail@jtheuer.de>
2012-02-28 19:28 ` Maciek Sakrejda <msakrejda@truviso.com>
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