Add a pool for TwistedConnection so that we re-use background threads
- Linguagem predominante
- Python
- Estrelas
- 102
- Forks
- 20
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Descrição
I keep getting this error when I make many simultaneous queries (klein -> alchimia -> PostgreSQL):
`QueuePool limit of size 5 overflow 10 reached, connection timed out, timeout 30`
I'm working around it right now by setting `max_overflow=-1` (http://docs.sqlalchemy.org/en/rel_0_8/core/pooling.html#sqlalchemy.pool.QueuePool.params.max_overflow) but I think that will cause problems if I actually open more connections than the Postgres database allows. So I think I (or someone) could implement a `Deferred`-returning pool that returns `Connections` asynchronously and has requests for connections wait in a queue.
I'm filing this here, because I think alchimia should come with such a pool built in. I'll take a look at what an implementation might look like on Monday.
Guia de contribuição
Avaliação
Esta issue ainda não foi avaliada.