From: Craig Ringer <craig@2ndquadrant.com>
To: Albe Laurenz <laurenz.albe@wien.gv.at>
To: Guillaume Cottenceau *EXTERN* <gc@mnc.ch>
To: pgsql-jdbc@postgresql.org <pgsql-jdbc@postgresql.org>
Subject: Re: performance question: protocol v2 vs v3
Date: Wed, 03 Dec 2014 19:24:49 +0800
Message-ID: <547EF301.3070706@2ndquadrant.com> (raw)
In-Reply-To: <A737B7A37273E048B164557ADEF4A58B17DA4AC7@ntex2010a.host.magwien.gv.at>
References: <m3ioi3a94e.fsf@mnc.ch>
<A737B7A37273E048B164557ADEF4A58B17DA4AC7@ntex2010a.host.magwien.gv.at>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-jdbc>
On 11/25/2014 06:45 PM, Albe Laurenz wrote:
> An explanation is maybe that prepared statements are handled
> using the extended query protocol, which only exists in v3.
> With the extended query protocol, each statement is first parsed,
> then parameters are bound to the statement and then the statement
> is executed, leading to three client-server round trips.
While Parse/Bind/Execute are separate steps, it is not correct to say
that this means three round trips.
Take a look at the conversation on the wire in Wireshark. You'll see
that generally, the Parse, Bind, Describe, Execute and Sync messages are
all actually sent in the same packet.
--
Craig Ringer http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
--
Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-jdbc
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: craig@2ndquadrant.com, laurenz.albe@wien.gv.at, gc@mnc.ch
Subject: Re: performance question: protocol v2 vs v3
In-Reply-To: <547EF301.3070706@2ndquadrant.com>
References: <m3ioi3a94e.fsf@mnc.ch> <A737B7A37273E048B164557ADEF4A58B17DA4AC7@ntex2010a.host.magwien.gv.at> <547EF301.3070706@2ndquadrant.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox