Re: Cascading replication: should we detect/prevent cycles?

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Josh Berkus <josh(at)agliodbs(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Cascading replication: should we detect/prevent cycles?
Date: 2013-01-27 18:13:27
Message-ID: CA+TgmoaK4w8o+6hGq3fXBKXPamXjhh8bBnDhVAjUS05OsmC3wg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, Jan 27, 2013 at 6:30 AM, Josh Berkus <josh(at)agliodbs(dot)com> wrote:
> So while testing some replication stuff on 9.2.2 I discovered that it's
> completely possible to connect a replica to itself. Seems like we ought
> to at least be able to detect and log *that*.

We could certainly alter the protocol so that it can detect that
situation, but like Simon, I dowanna. I rarely get the chance to
agree wholeheartedly with Simon, so let me just take a moment to revel
in it here: you have discovered a non-problem problem. Sure, if you
do that, nothing useful will happen. But there are lots of non-useful
things in the world you can do, and it is neither practical nor
sensible to try to prevent them all. And again, yes, you could do
that by accident when you meant to do something more sane, but again,
there are any number of other ways to accidentally do something truly
worthless.

If we're going to start installing safeguards against doing stupid
things, there's a long list of scenarios that happen far more
regularly than this ever will and cause far more damage.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2013-01-27 18:15:05 Re: allowing privileges on untrusted languages
Previous Message Tom Lane 2013-01-27 18:09:50 Re: allowing privileges on untrusted languages