Return-Path: Mailing-List: contact ibatis-user-java-help@incubator.apache.org; run by ezmlm Delivered-To: mailing list ibatis-user-java@incubator.apache.org Received: (qmail 74885 invoked by uid 99); 6 Dec 2004 11:19:58 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: neutral (hermes.apache.org: local policy) Received: from mail07.svc.cra.dublin.eircom.net (HELO mail07.svc.cra.dublin.eircom.net) (159.134.118.23) by apache.org (qpsmtpd/0.28) with SMTP; Mon, 06 Dec 2004 03:19:55 -0800 Received: (qmail 98962 messnum 2841058 invoked from network[83.71.72.86/83-71-72-86.bas1.chf.cork.eircom.net]); 6 Dec 2004 11:19:48 -0000 Received: from 83-71-72-86.bas1.chf.cork.eircom.net (HELO ?127.0.0.1?) (83.71.72.86) by mail07.svc.cra.dublin.eircom.net (qp 98962) with SMTP; 6 Dec 2004 11:19:48 -0000 Message-ID: <41B44050.5080607@corksurf.com> Date: Mon, 06 Dec 2004 11:19:44 +0000 From: Peter Bracken Reply-To: bracken@corksurf.com Organization: CorkSurf User-Agent: Mozilla Thunderbird 1.0RC1 (Windows/20041201) X-Accept-Language: en-us, en MIME-Version: 1.0 To: ibatis-user-java@incubator.apache.org Subject: iBatis Connection Management Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked Hi, I've recently started using iBatis for one of my projects and I like it but I'm having problems with the database connection. By default the database stops returning results after 122 queries, after that I get the following exception: [6/12/2004 9:40:14] [Error getting latest messages: Server configuration denies access to data source] java.sql.SQLException: Server configuration denies access to data source at com.mysql.jdbc.MysqlIO.init(Unknown Source) at com.mysql.jdbc.Connection.connectionInit(Unknown Source) at com.mysql.jdbc.jdbc2.Connection.connectionInit(Unknown Source) at com.mysql.jdbc.Driver.connect(Unknown Source) at java.sql.DriverManager.getConnection(DriverManager.java:512) at java.sql.DriverManager.getConnection(DriverManager.java:171) at com.ibatis.common.jdbc.SimpleDataSource.popConnection(SimpleDataSource.java:572) at com.ibatis.common.jdbc.SimpleDataSource.getConnection(SimpleDataSource.java:215) at com.ibatis.sqlmap.engine.transaction.jdbc.JdbcTransaction.init(JdbcTransaction.java:45) at com.ibatis.sqlmap.engine.transaction.jdbc.JdbcTransaction.getConnection(JdbcTransaction.java:78) at com.ibatis.sqlmap.engine.mapping.statement.GeneralStatement.executeQueryForList(GeneralStatement.java:118) at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForList(SqlMapExecutorDelegate.java:626) at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForList(SqlMapExecutorDelegate.java:598) at com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl.queryForList(SqlMapSessionImpl.java:107) at com.ibatis.sqlmap.engine.impl.SqlMapClientImpl.queryForList(SqlMapClientImpl.java:76) at com.corksurf.chatterbox.ChatterBoxManager.getLatestMessages(ChatterBoxManager.java:106) It's a web-app so I thought maybe reloading the Context might do something but no. I need to restart Tomcat to be able to run a query again. I changed some values in the config.xml file for pooling: Now I get the exceptions after around a hundred queries. It seems to work fine if I use a JNDI resource, which I will be doing in my app. I noticed this problem because I didn't have my Unit Tests configured to use the JNDI resource. Is it a known issue? Or is it something wrong with my config? Thanks Peter Bracken