I have a Django App with a pretty standard server stack
- DB Backend : MySQL
- WSGI Server : Gunicorn
- Async worker class : Gevent
I want Django to pool MySQL connections rather than creating connections on every request.
Starting 1.6, Django has introduced persistent connections but there are issues with async workers.
Hence, either a different MySQL backend is required or app level connection pooling. I've read several of them. Some of them are very old articles. Following are some:
Django MySQL backends
App level Connection pool
Some Patches are also available
Some other approaches
I'm really confused as to which approach among these is the best way to pool connections? Any Help is highly appreciated.