X-Original-To: pgsql-hackers-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 67B6E11F65B3 for ; Thu, 13 Apr 2006 12:15:13 -0300 (ADT) X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Score: 0.111 X-Spam-Level: X-Spam-Status: No, score=0.111 required=5 tests=[AWL=0.111] Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id R1oTIvP5pyvk for ; Thu, 13 Apr 2006 12:15:09 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from stark.xeocode.com (stark.xeocode.com [216.58.44.227]) by postgresql.org (Postfix) with ESMTP id 00F9111F65FE for ; Thu, 13 Apr 2006 12:15:08 -0300 (ADT) Received: from localhost ([127.0.0.1] helo=stark.xeocode.com) by stark.xeocode.com with smtp (Exim 3.36 #1 (Debian)) id 1FU3X7-00082a-00; Thu, 13 Apr 2006 11:14:57 -0400 To: Martijn van Oosterhout Cc: Dave Page , pgsql-hackers@postgresql.org, Hiroshi Inoue Subject: Re: Practical impediment to supporting multiple SSL libraries References: <20060413113405.GF7362@svana.org> In-Reply-To: <20060413113405.GF7362@svana.org> From: Greg Stark Organization: The Emacs Conspiracy; member since 1992 Date: 13 Apr 2006 11:14:57 -0400 Message-ID: <87ek01ik26.fsf@stark.xeocode.com> Lines: 26 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Archive-Number: 200604/504 X-Sequence-Number: 82227 Martijn van Oosterhout writes: > On Thu, Apr 13, 2006 at 12:12:25PM +0100, Dave Page wrote: > > > Ok. I'm not sure what this "double copying" you're referring > > > to is, > > > > The libpq driver copies results out of the PGresult struct into the > > internal QueryResult classes. With libpq out of the loop, data can go > > straight from the wire into the QR. > > Hmm, the simplest improvement I can think of is one where you > register a callback that libpq calls whenever it has received a new > tuple. That could be useful for applications but I think a driver really wants to retain control of the flow of control. To make use of a callback it would have to have an awkward dance of calling whatever function gives libpq license to call the callback, having the callback stuff the data in a temporary space, then checking for new data in the temporary space, and returning it to the user. -- greg