Re: [COMMITTERS] pgsql: Log replication connections only when log_connections is on

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: [COMMITTERS] pgsql: Log replication connections only when log_connections is on
Date: 2011-01-19 12:44:06
Message-ID: AANLkTimrxQvXztHcR_a_DZzQ+qt6SzeDV6VSc8nUL69c@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On Wed, Jan 19, 2011 at 13:36, Simon Riggs <simon(at)2ndquadrant(dot)com> wrote:
> On Tue, 2011-01-18 at 19:04 +0000, Magnus Hagander wrote:
>> Log replication connections only when log_connections is on
>>
>> Previously we'd always log replication connections, with no
>> way to turn them off.
>
> You noted that the code was there intentionally, yet you also couldn't
> see the reason. That is not a great reason to change it. It's especially
> not a great reason to make the change quickly.

Yes. And I brought it up in discussion, and the consensus was to
change it to be consistent.

And per that thread, there was also no consensus on ever *adding* it
that way - if I'd realized it was that way back then, I would've
objected at the time. I didn't realize it until I started seeing the
systems in production more.

> The log entry served a very specific purpose, which was helping people
> to diagnose problems with replication connectivity. It isn't practical
> or sensible to force people to use log_connections to help with that;
> that is a sledgehammer to crack a nut. Few people have it turned on in
> production, so turning it on after a problem happened doesn't help
> diagnose things.

Again, if you read the thread, the consensus was to do it the simple
way and make it configurable by that one. The other suggestion was to
turn log_connections into an enum, which was considered unnecessarily
complicated.

> The negative impact of this was a couple of log lines. No bug. Plus I
> don't see any reason to introduce an incompatibility with the log output
> from 9.0.

The inability to remove it has certainly annoyed me, and I know a few
others who have commented on it. And it's inconsistent behavior,
something we in general try to avoid.

--
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.com/

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Simon Riggs 2011-01-19 12:55:08 Re: [COMMITTERS] pgsql: Log replication connections only when log_connections is on
Previous Message Simon Riggs 2011-01-19 12:36:05 Re: [COMMITTERS] pgsql: Log replication connections only when log_connections is on

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2011-01-19 12:47:12 Re: pg_dump directory archive format / parallel pg_dump
Previous Message Magnus Hagander 2011-01-19 12:37:24 Re: pg_basebackup for streaming base backups