Re: bad COPY performance with NOTIFY in a trigger

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Filip Rembiałkowski <filip(dot)rembialkowski(at)gmail(dot)com>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: bad COPY performance with NOTIFY in a trigger
Date: 2016-02-04 22:41:13
Message-ID: 5721.1454625673@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

=?UTF-8?Q?Filip_Rembia=C5=82kowski?= <filip(dot)rembialkowski(at)gmail(dot)com> writes:
> A table has a trigger.
> The trigger sends a NOTIFY.
> Test with COPY FROM shows non-linear correlation between number of inserted
> rows and COPY duration.

No surprise, see AsyncExistsPendingNotify. You would have a lot of other
performance issues with sending hundreds of thousands of distinct notify
events from one transaction anyway, so I can't get terribly excited about
this.

regards, tom lane

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Harald Fuchs 2016-02-05 08:40:44 Re: bad COPY performance with NOTIFY in a trigger
Previous Message Filip Rembiałkowski 2016-02-04 21:12:39 bad COPY performance with NOTIFY in a trigger