Live data from Hacker News

Show HN: 1M rows/s from Postgres to Python

magic.io

1–10 of 94 posts

Re: Show HN: 1M rows/s from Postgres to Python

#6
post #2

asyncpg was developed by @redcrowbar and me. Ask us anything ;)

May be I am reading the benchmarks wrong, but does it mean I can get a 2x speedup in my end to end query execution from moving from aiopg to asynpg alone without any server side changes or query optimizations?

Re: Show HN: 1M rows/s from Postgres to Python

#8
post #3
post #2

asyncpg was developed by @redcrowbar and me. Ask us anything ;)

Does this automatically escape/convert things like datetimes in a query or does that need to be done separately? The docs are a little sparse on details. Looks fantastic anyway!

Yes, query arguments are converted automatically. Results are converted into Python types as expected (including arrays and composite types).

Re: Show HN: 1M rows/s from Postgres to Python

#9
post #5
post #2

asyncpg was developed by @redcrowbar and me. Ask us anything ;)

Great work, thanks for sharing. Very impressive speed. I didn't know about uvloop, that's a cool project: http://magic.io/blog/uvloop-blazing-fast-python-networking/

Yep, it's also much more stable now, 3 months after that article was posted. I plan to make a new blog post about it soon.

Re: Show HN: 1M rows/s from Postgres to Python

#10
post #6
post #2

asyncpg was developed by @redcrowbar and me. Ask us anything ;)

May be I am reading the benchmarks wrong, but does it mean I can get a 2x speedup in my end to end query execution from moving from aiopg to asynpg alone without any server side changes or query optimizations?

We intentionally benchmarked simple queries to measure the overhead of the driver implementation. So, the 2x speedup really means 50% reduction in overhead.
Post reply on HN