I've used the standard DB constant approach for connecting to a MySQL db: DB = Sequel::Mysql2::Database.connect(mysql_options)
When the MySQL servers gets restarted, all subsequent connections fail: Sequel::DatabaseDisconnectError: Mysql2::Error: MySQL server has gone away I'm now connecting using Sequel::Document: def connect! Sequel::Model.db = Sequel::Mysql2::Database.connect(mysql_options) end I call this method when starting the app and would like to call it on Sequel::DatabaseDisconnectError, but I can't figure out where to rescue. Maybe my approach is wrong... -- You received this message because you are subscribed to the Google Groups "sequel-talk" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/sequel-talk?hl=en.
