开发者

Access to Apache::DBI from DBI

Is it possible to access a Apache::DBI database handle from a perl script (that isn't running under mod_perl).

What I am looking for is database pooling for my perl scripts, I have a fair number of database sources (oracle/mysql) and a growing number of scripts.

Some ideas like SQLRelay, using Oracle10XE with database links and poolin开发者_如何学Pythong, and or convert all scripts to SOAP calls, etc are becoming more and more viable. But if there was a mechanism for reusing Apache::DBI I could fight this a bit.

I have no non-perl requirements, so we don't have a php/jdbc implementation or similar to deal with.

Thanks


First off it helps to remember that DBI/DBD is not a wire protocol, but an API over diverse data sources.

Since you are wanting to connect to a pool of database connections from separate processes, DBIx::Connector is not appropriate for that, and Rose::DB seems an odd choice too (they are both wrappers over DBI). You are looking for something like DBD::Proxy or DBD::Gofer, which let you connect multiple processes to a shared database handle.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜