Re: Async client for PostgreSQL?

2012-09-03 Thread calderone . jeanpaul
On Saturday, September 1, 2012 3:28:52 PM UTC-4, Laszlo Nagy wrote: Hi does running on tornado imply that you would not consider twisted http://twistedmatrix.com ? If not, twisted has exactly this capability hiding long running queries on whatever db's behind

Re: Async client for PostgreSQL?

2012-09-02 Thread Laszlo Nagy
Hmm, I was suggesting that you could replace the whole DB driver with a webservice implemented with twisted, if you rule out threads then with ampoule doing it with a process pool and consume this webservice with the tornado side asynchronously. I see. I'm sorry, I misunderstood. So this

Re: Async client for PostgreSQL?

2012-09-01 Thread Werner Thie
On 8/31/12 7:17 PM, Laszlo Nagy wrote: Is there any extension for Python that can do async I/O for PostgreSQL with tornadoweb's ioloop? Something like: class MainHandler(tornado.web.RequestHandler): @tornado.web.asynchronous def get(self):

Re: Async client for PostgreSQL?

2012-09-01 Thread Laszlo Nagy
Hi does running on tornado imply that you would not consider twisted http://twistedmatrix.com ? If not, twisted has exactly this capability hiding long running queries on whatever db's behind deferToThread(). All right, I was reading its documentation

Re: Async client for PostgreSQL?

2012-09-01 Thread Werner Thie
On 9/1/12 9:28 AM, Laszlo Nagy wrote: Hi does running on tornado imply that you would not consider twisted http://twistedmatrix.com ? If not, twisted has exactly this capability hiding long running queries on whatever db's behind deferToThread(). All right, I was reading its documentation

Re: Async client for PostgreSQL?

2012-09-01 Thread jwp
On Friday, August 31, 2012 10:17:18 PM UTC-7, Laszlo Nagy wrote: Is there any extension for Python that can do async I/O for PostgreSQL As others point out, the easiest route is using one of the blocking drivers with threads and emulate async operations. However, the low-level parts of

Async client for PostgreSQL?

2012-08-31 Thread Laszlo Nagy
Is there any extension for Python that can do async I/O for PostgreSQL with tornadoweb's ioloop? Something like: class MainHandler(tornado.web.RequestHandler): @tornado.web.asynchronous def get(self): pg_connection.(long_taking_query_sql,params,callback=self.on_query_opened)