Re: contrib: hack for psycopg2 performance

Daniele Varrazzo <[email protected]> Tue, 11 May 2010 10:32:44 +0100
Newsgroups gmane.comp.python.db.psycopg.devel
Message-ID <[email protected]>
On Tue, May 11, 2010 at 1:24 AM, P. Christeas <[email protected]> wrote:
> On Tuesday 11 May 2010, Daniele Varrazzo wrote:
>>...
>> so the
>> advantage of the *Params should be *very* high to offset the burden of
>> keeping PQexec-based routines around as a fallback.
>>
>>...
>
> In short: I don't claim to have a trivial/obvious solution that would fit all
> and deliver a perfect result. I appreciate your work and the fact that it
> works as advertised.
>
> But I had to give it a try! Hack, measure, and then compare the two ways.
> Indeed, the first test (one that is in sandbox) does perform well enough to say
> it had worth it (have you tried that test?).
>
> I'm really also looking forward to using binary /results/ from queries
> (although these are even harder to support).
>
> Frankly, my expectation is not that you merge this code into the trunk today!,
> but experiment and see if we can squeeze more performance out of the psycopg
> connector. Let's just reach a working beta, forecast the possible shortcomings
> (like the one you mentioned) and put the hacked code into a real project.

You did good, and I'm happy Federico has an idea about where to put
PQexecParams to use. I am just avoiding to hide the stumbling blocks
over the path, but your idea is absolutely worthy.

Keep up the good work! Cheers,

-- Daniele