Thanks Andras for the suggestion. I made my Torque.properties identical to yours (except of course the url, user, and password) and again all works fine for the first 9 queries, then the 10th one hangs ... haven't been able to recover from the hang yet. Even recycling Tomcat doesn't bring the database back.

Does this have anything to do with new database connections being created with each doSelect and they aren't being timed out fast enough? This looks like it is probably more for the Torque User list.

Best Regards,
Dave

At 10:12 PM 4/4/2003 +0300, [EMAIL PROTECTED] wrote:
Hi,

Check your Torque.properties file and use Jdbc2PoolDataSourceFactory as the datasource factory something like this:


torque.dsfactory.default.factory=org.apache.torque.dsfactory.Jdbc2PoolDataSourceFactory
torque.dsfactory.default.pool.defaultMaxActive=10
torque.dsfactory.default.pool.testOnBorrow=true
torque.dsfactory.default.pool.validationQuery=SELECT 1
torque.dsfactory.default.connection.driver = org.gjt.mm.mysql.Driver
torque.dsfactory.default.connection.url = jdbc:mysql://localhost:3306/<db name>
torque.dsfactory.default.connection.user = <user>
torque.dsfactory.default.connection.password = <password>


, you can rename the connection, just put somethog else instead of default

cheers
andras


>-----Original Message----- >From: ext Dave Frary [mailto:[EMAIL PROTECTED] >Sent: 04 April, 2003 04:02 >To: [EMAIL PROTECTED] >Subject: DataBaseBrowser Error > > >Hi, > >Yet another Jetspeed newbie. > >I'm playing around with the DataBaseBrowser coffee example in the >tutorial. I get a java.lang.NullPointerException when I try >to edit for >the 10th time (first 9 work fine). It's complaining trying to do the >doSelect with the Torque criteria statement looking up the >rowid to display >the Edit portlet. Is this possibly because only 10 connections are >allocated and somehow they aren't being cleaned up? > >I'm using Jetspeed 1.4dev4 (about a month or so old) and >Tomcat 4.18 LE. > >Any help or pointers would be greatly appreciated as I see the >same problem >with the DataBaseBrowser I created. > >thanks, >Dave > >partial stacktrace > >java.lang.NullPointerException: Connection object was null. >This could be >due to a misconfiguration of the DataSourceFactory. Check the >logs and >Torque.properties to better determine the cause. > at >org.apache.torque.util.Transaction.rollback(Transaction.java:179) > at org.apache.torque.util.BasePeer.doSelect(BasePeer.java:1333) > at >com.bluesunrise.jportal.om.BaseCoffeesPeer.doSelectVillageRecor >ds(BaseCoffeesPeer.java:384) > at >com.bluesunrise.jportal.om.BaseCoffeesPeer.doSelectVillageRecor >ds(BaseCoffeesPeet.java:351) > at >com.bluesunrise.jportal.om.BaseCoffeesPeer.doSelect(BaseCoffees >Peer.java:320) > at >com.bluesunrise.jportal.modules.actions.portlets.TutorialCoffee >sAction.buildNormalContext(TutorialCoffeesAction.java:102) > > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > >

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to