From: Greg Stark <gsstark@mit.edu>
To: L J Bayuk <ljb220@mindspring.com>
Cc: Nigel J. Andrews <nandrews@investsystems.co.uk>
Cc: pgsql-interfaces@postgresql.org
Subject: Re: pgin.tcl pg_exec_prepared slow (was: Released...)
Date: 06 Jul 2004 21:27:45 -0400
Message-ID: <878ydwsj1q.fsf@stark.xeocode.com> (raw)
In-Reply-To: <20040706010731.GA15183@bxlbisnugqvi.mindspring.com>
References: <24110.1087945736@sss.pgh.pa.us>
<Pine.LNX.4.21.0406302310340.12226-100000@ponder.fairway2k.co.uk>
<20040706010731.GA15183@bxlbisnugqvi.mindspring.com>
L J Bayuk <ljb220@mindspring.com> writes:
> The delay we are seeing (about 40 ms) is from the time the client sends the
> Bind message to PostgreSQL until it gets a TCP ACK back.
You might consider disabling the NAGLE algorithm. It can delay acks like this.
You could do this with setsockopt(SOL_TCP, TCP_NODELAY,...)
The problem is that while this would be perfectly appropriate for things like
bind messages, it's entirely inappropriate for the bulk data transfer
of the results of a query.
I would not suggest enabling TCP_NODELAY for all data. And I'm not sure how
implementations behave if you turn it on and off.
--
greg
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 using the --to and --cc options:
reply via email
To: pgsql-interfaces@postgresql.org
Cc: gsstark@mit.edu, ljb220@mindspring.com, nandrews@investsystems.co.uk
Subject: Re: pgin.tcl pg_exec_prepared slow (was: Released...)
In-Reply-To: <878ydwsj1q.fsf@stark.xeocode.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