in reply to DBI::connect_cached, Apache::DBI and Class::DBI

Apache::DBI and DBI::connect_cached work fine, but Class::DBI uses Ima::DBI, which doesn't play nicely with Apache::DBI. This will not really affect you unless you either use transactions (Apache::DBI has a cleanup_handler to do safety rollbacks at the end of each request, but Ima::DBI prevents it from working) or use something like Class::DBI::mysql which will try to load open a database connection when you use it and pull it in from your startup.pl (before forking). I've written explanations with sample code and workarounds on the Class::DBI mailing list and the mod_perl list.
  • Comment on Re: DBI::connect_cached, Apache::DBI and Class::DBI

Replies are listed 'Best First'.
Re^2: DBI::connect_cached, Apache::DBI and Class::DBI
by Arunbear (Prior) on Nov 30, 2004 at 09:00 UTC
    I've written explanations with sample code and workarounds on the Class::DBI mailing list and the mod_perl list.
    Considering the importance of this topic, why not post that here on Perlmonks - it would make a good tutorial.
      I'm hoping it will soon be irrelevant because the problem will be fixed. In the meantime here's the post.