--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django...@googlegroups.com.
To unsubscribe from this group, send email to django-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Hi Jayapal,
What you want is a connection pool for Postgres. Happily, such exists in the form of pgpool-2: http://pgpool.projects.postgresql.org/
The way it works is pgpool-2 runs as a separate daemon and spawns a configurable number of database connections. You configure pgpool-2 to listen for incoming database connections on whatever port you prefer, 5433 for example, and you tell it to talk to your database on e.g. port 5432. In your Django settings, you use the standard "postgresql_psycopg2" driver and tell it to connect to the database via port 5433. Django then uses the pooled connections, and you don't have to worry about the overhead of setting up new connections or tearing down old ones.
Hope that helps,
---Peter