CanopyTax/asyncpgsa

Benchmark

Closed this issue · 3 comments

The only reason I see to use asyncpg is performance benefits. Do you have any benchmarks for comparsion your lib with aiopg? It's not obvious for me that alchemy layer don't diminish any asyncpg advantages.

@imbolc This will kind of depend on your stack. If I was to create benchmarks, and they did show that this lib is faster, that still doesnt mean it will be faster for you. It would probably be best if you ran your own benchmarks against your own database. But you have a good point. I might run some benchmarks when I get around to it for simple comparison sakes.

Asyncpg already has some benchs for comparison itself with other libs including aiopg. I think it's a good start to just add your lib there

the bench framework isnt really designed for running sqlalchemy queries. It would take a significant amount of work.

Instead I wrote a really quick timeit script that compares a very basic SQ query against both aiopg and asyncpgsa. Looks like asyncpgsa is still faster (about 2/3 the time of aiopg).

You can see the results on the readme now.