From: John Coers <coers@intrinsity.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-general@postgresql.org
Subject: Re: Copy
Date: Tue, 01 May 2001 10:49:11 -0500
Message-ID: <3AEEDAF7.F1FA2AB6@intrinsity.com> (raw)
References: <Pine.LNX.4.21.0104261634460.2565-100000@olympus.scw.org>
<3AE89D2C.409BEF42@intrinsity.com>
<3AEDB916.BE3123A0@intrinsity.com>
<3AEDDECF.6B3ED075@intrinsity.com>
<391.988668966@sss.pgh.pa.us>
Tom Lane wrote:
>
> John Coers <coers@intrinsity.com> writes:
> > Does a COPY FROM block? In case I am using the wrong terminology,
> > what I need to know is if I have multiple clients performing COPY FROM...PQputline()
> > using asynchronous connections, will I lose data?
>
> No.
>
> > Will the server simply execute them serially?
>
> They'll be executed in parallel, just the same as if each client had
> done a bunch of INSERTs wrapped in a BEGIN/END block. You'd only see
> problems if clients inserted conflicting data (eg, identical keys in
> a column with a UNIQUE index). You may care to read the documentation
> about multi-version concurrency control and locking.
>
> regards, tom lane
hmmmm...I get best performance with N=2 and force the clients to keep trying to
get a connection. If I leave the default of N=32 the machine gets bogged down
to a complete standstill by 32 copies of 15k rows of data. The CPU doesn't seem
stressed -- what may be causing the bottleneck?
--
John Coers Intrinsity, Inc.
coers@intrinsity.com Austin, Texas
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-sql@postgresql.org
Cc: coers@intrinsity.com, tgl@sss.pgh.pa.us, pgsql-general@postgresql.org
Subject: Re: Copy
In-Reply-To: <3AEEDAF7.F1FA2AB6@intrinsity.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