Re: Up to 50x degradation in dblink performance when receiving notice traffic 19 vs 18

From: vignesh C <vignesh21(at)gmail(dot)com>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: Merlin Moncure <mmoncure(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Up to 50x degradation in dblink performance when receiving notice traffic 19 vs 18
Date: 2026-09-25 06:15:20
Message-ID: CALDaNm2YtVcq+__0-TdOgg7_YHoQKcc=yjD7zPtMgti-hdT3cw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, 25 Sept 2026 at 10:27, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
>
> On Fri, Sep 25, 2026 at 1:39 PM vignesh C <vignesh21(at)gmail(dot)com> wrote:
> > Thanks for verifying, here is a v2 version
>
> Thanks for the patch!
> +1 to calling errhidestmt(true) and errhidecontext(true).
>
> + /*
> + * Don't log the local statement or context. This runs once for every
> + * message the remote server sends, and LOG passes the default
> + * log_min_error_statement, so each message would otherwise repeat the
> + * whole text of whatever local query is running. The local context only
> + * says where libpq happened to be reading input, not what caused the
> + * message.
> + */
>
> This comment sounds a bit redundant and indirect to me. How about a simpler
> one like this?
>
> Omit the local statement and context from each remote message.
> They can help identify the caller, but repeating them for every
> message could greatly increase log volume.

Thanks, this looks enough. Here is an updated v3 version patch for the same.

Regards,
Vignesh

Attachment Content-Type Size
v3-0001-Don-t-log-local-statement-and-context-with-remote.patch application/octet-stream 2.1 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message solai v 2026-09-25 06:23:22 Re: Add a permission check to pg_stat_get_backend_subxact()
Previous Message Manu 2026-09-25 06:13:40 Re: REPACK (CONCURRENTLY) can silently lose updates when the toast table is rewritten