views:

12

answers:

0

I have a Jruby app that spins up several background Java threads that share an ActiveRecord (2.3.5) connection. If they sleep for some time and then try to do something database related, the first queries never execute. I believe this is because the connections are stale, but the code itself doesn't throw any errors.

I've tried doing a ActiveRecord::Base.connection.verify! but it still craps out. I'm using ActiveRecord jdbcmysql 0.9.7 but am now trying the newest 1.0.2 to see if that helps.