[DB-SIG] asyncio support
INADA Naoki
songofacandy at gmail.com
Mon Nov 11 10:43:38 CET 2013
I think having definition about what method returns Future is good.
For example:
con = yield from pymysql.connect_async(...) # connection may cause
cur = con.cursor() # cursor creation should done without asyncio
yield from cur.execute("...") # execute may use asyncio
row = yield from cur.fetchone() # fetch also uses asyncio
for row in cur: # raises NotImplementedError
On Mon, Nov 11, 2013 at 5:49 AM, Tony Locke <tlocke at tlocke.org.uk> wrote:
> What sort of thing do you have in mind? Perhaps something where the
> execute() method returns immediately, and a callback function is called
> when the query is complete?
>
> This could be implemented in a library on top of DB-API. But should it be
> part of the spec?
>
> Cheers,
>
> Tony.
>
>
> On 25 October 2013 08:27, INADA Naoki <songofacandy at gmail.com> wrote:
>
>> Does someone consider DB-API for asyncio?
>>
>>
>> --
>> INADA Naoki <songofacandy at gmail.com>
>>
>> _______________________________________________
>> DB-SIG maillist - DB-SIG at python.org
>> https://mail.python.org/mailman/listinfo/db-sig
>>
>>
>
> _______________________________________________
> DB-SIG maillist - DB-SIG at python.org
> https://mail.python.org/mailman/listinfo/db-sig
>
>
--
INADA Naoki <songofacandy at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/db-sig/attachments/20131111/7cca8f8d/attachment.html>
More information about the DB-SIG
mailing list