From: David R. <woo...@ro...> - 2003-08-07 22:29:24
|
--- Thomas E Jenkins <mo...@ca...> wrote: > > I suppose I could make this code available if anyone wants > > it, but the "ping" logic is database-specific. > > I'd love to see this code at least as a jumping off point for a MySQL > (and Postgres) version. It's attached in a tarball. I hope no one minds that I sent it to the list--the file size is tiny. The code in kinterbasdb_DBPool.py is slightly complicated by the subclassing difficulties imposed by MiscUtils.DBPool.DBPool; the actual "resilience code" is straightforward. If the DB API Spec included a Connection.ping method to test the connectedness of a Connection, a totally generic cross-db-module version could be written. Even without a standard ping method, implementing individualized "pings" for various databases would be simple. kinterbasdb_DBPool.py relies on another module, tolerant_callable_proxy.py. Both are ripped out of a broad package hierarchy, so they won't work "out of the box". __________________________________ Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com |