• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

DB timeout Exceptions / How to set c3po settings?

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm having lots of problems where JForums is trying to use a DB connection from the c3po pool but MySQL has closed the connection already.
The MySQL interactive_timeout and wait_timeout is 300.
I've set the jforum timeout to be 250 but that doesn't seem to work at all or it's just ignored?

I've looked at the c3po documentation and I want to use the testConnectionsOnCheckout option. However, the jforum-custom.conf seems quite a bit different than the c3po documented config format.

Can I just do this:

database.connection.testConnectionsOnCheckout=true

Thank you.

[originally posted on jforum.net by MarkSwanson]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Create the c3p0.properties with all keys you want and put it at WEB-INF/classes

That should work.

Version 2.1.7 of JForum (still in beta, and you can get it at http://www.jforum.net/beta/latest_dev.jsp) provides a key named "c3p0.extra.params" in the file SystemGlobals.properties, that you can use to pass extra configuration data to the connection pool.

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the response.
I'm thinking of trying the latest beta.
Others have reported that the admin privs are changed in some way in the latest beta. You have posted that it shouldn't be that way and won't be in the final release. I'm wondering if I have to look out for this issue or has it been fixed in the latest beta?

Thanks.

[originally posted on jforum.net by MarkSwanson]
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!