Connection pooling w/ DBD::Gofer

[email protected] ("Cosimo Streppone")
Newsgroups perl.dbi.users
Message-ID <op.vogzxm2ms5ttvb@cd01>
Hi there,

It's been a while since I first read about DBD::Gofer.

I will soon be reaching the point where we're saturating
the database with useless, maybe idle, connections, so
time has come to test-drive it in production.

Scenario:

- an apache/mod_perl/Plack/PSGI app, around ~500 req/s
   running on a few backends.

- on each backend, every child connects to the database.
   For this particular app, 4 db connections to 2 different dbs are  
required:

     db1 master (write-only) + db1 slave (read-only)
   + db2 master (write-only) + db2 slave (read-only)

- 100 children * 4 = 400 connections per backend at startup

- The majority of use cases are not transactional and
   90% read/10% write, but I also have a few transactions,
   and that is going to increase soon.

I'd like to get some advice related to your experience
in using DBD::Gofer for connection pooling.

I'm thinking of running a per-backend Gofer-based server
that just pools connections to the DBs.

All the apache/mod_perl/PSGI children would then
connect to the local Gofer daemon over a unix socket
or maybe localhost:<someport>.

Thanks,

-- 
Cosimo
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.