Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm looking for a pooling solution for mysql that is independent of the language. I am using PGBouncer as an example because it

  1. Resides on the server the database is on
  2. Just change the connection string to use the pooling connector
  3. No modification to the code required

Is there something similiar in MySQL where I can using pooling by installing a 3rd party connector and just connect through that port?

share|improve this question

migrated from Jun 2 '13 at 7:53

This question came from our site for professional and enthusiast programmers.

suggesting we move this to – Chris Travers Jun 1 '13 at 14:20

This started off as a comment but it's getting a bit long.

Perhaps you could provide a better description of what it is you actually want rather than simply say it's like something else.

If you want multiple clients to use the same connection, then it must be implemented in the DBMS, otherwise you have no session management. Further you need to advise how you intend dealing with issues of state spanning more than a single request/response (i.e. transactions).

It would also be helpful to know why you want it. MySQL has a very different setup cost and per-session overhead cost compared to PostgreSQL - why do you think it needs it, and why you think it would actually yeild any benefit.

share|improve this answer

Actually PGBouncer is good in pooling and distributing connections from the DB server itself .. suppose the following example

Say you have 10 application servers and 1 database server configured for 500 maximum connections. You set the individual application server pool sizes to 50. Now you need to add a new application server. You would have to tune all 10 of your old servers dropping their pool sizes down to make room for the new one. This problem gets more and more severe as you add more servers.

Also, tuning individual pool sizes per client means there is a chance that one server is starving while others have pooled connections sitting idle – the connections aren’t shared

share|improve this answer
And how does that answer the question if something similar exists for MySQL? – a_horse_with_no_name Jun 4 '14 at 14:22
For MySQL, data connections (your datasource) could be wrapped up into a different layer that will be responsible only for assigning connections to application servers giving the ability to distribute connections and also to share them to eliminate the idleness issue. – msoliman Jun 5 '14 at 8:59

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.