You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Tomek Rękawek (JIRA)" <ji...@apache.org> on 2016/03/02 13:33:18 UTC
[jira] [Created] (OAK-4082) Don't pool prepared statements using
lists
Tomek Rękawek created OAK-4082:
----------------------------------
Summary: Don't pool prepared statements using lists
Key: OAK-4082
URL: https://issues.apache.org/jira/browse/OAK-4082
Project: Jackrabbit Oak
Issue Type: Bug
Components: rdbmk
Reporter: Tomek Rękawek
Fix For: 1.4, 1.6
In the RDBDocumentStoreJDBC we should invoke {{setPoolable(false)}} on all prepared statements containing a list of ids. Otherwise we can get exceptions like this:
{noformat}
15:45:58 Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Can't create more than max_prepared_stmt_count statements (current value: 16382)
15:45:58 at sun.reflect.GeneratedConstructorAccessor23.newInstance(Unknown Source)
15:45:58 at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
15:45:58 at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
15:45:58 at com.mysql.jdbc.Util.handleNewInstance(Util.java:400)
15:45:58 at com.mysql.jdbc.Util.getInstance(Util.java:383)
15:45:58 at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:980)
15:45:58 at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3847)
15:45:58 at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3783)
15:45:58 at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2447)
15:45:58 at com.mysql.jdbc.ServerPreparedStatement.serverPrepare(ServerPreparedStatement.java:1514)
15:45:58 at com.mysql.jdbc.ServerPreparedStatement.<init>(ServerPreparedStatement.java:389)
15:45:58 at com.mysql.jdbc.ServerPreparedStatement.prepareBatchedInsertSQL(ServerPreparedStatement.java:2832)
15:45:58 at com.mysql.jdbc.PreparedStatement.executeBatchedInserts(PreparedStatement.java:1524)
15:45:58 at com.mysql.jdbc.PreparedStatement.executeBatch(PreparedStatement.java:1262)
15:45:58 at org.apache.jackrabbit.oak.plugins.document.rdb.RDBDocumentStoreJDBC.insert(RDBDocumentStoreJDBC.java:302)
15:45:58 at org.apache.jackrabbit.oak.plugins.document.rdb.RDBDocumentStoreJDBC.update(RDBDocumentStoreJDBC.java:446)
15:45:58 at org.apache.jackrabbit.oak.plugins.document.rdb.RDBDocumentStore.bulkUpdate(RDBDocumentStore.java:456)
15:45:58 ... 21 more
{noformat}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)