Re: inconsistent application_name use in logical workers

From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: Petr Jelinek <petr(dot)jelinek(at)2ndquadrant(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: inconsistent application_name use in logical workers
Date: 2017-06-06 13:07:19
Message-ID: 03d97417-37fe-faba-872f-ef0ac153fb45@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 6/6/17 06:51, Petr Jelinek wrote:
> On 06/06/17 04:19, Peter Eisentraut wrote:
>> The logical replication code is supposed to use the subscription name as
>> the fallback_application_name, but in some cases it uses the slot name,
>> which could be different. See attached patch to correct this.
>
> Hmm, well the differentiation has a reason though. The application_name
> is used for sync rep and having synchronization connection using same
> application_name might have adverse effects there because
> synchronization connection can be in-front of main apply one, so sync
> rep will think something is consumed while it's not.

True, we should use a different name for tablesync.c. But the one in
worker.c appears to be a mistake then?

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2017-06-06 13:09:40 Re: Challenges preventing us moving to 64 bit transaction id (XID)?
Previous Message Peter Eisentraut 2017-06-06 13:05:03 Re: Challenges preventing us moving to 64 bit transaction id (XID)?