Re: pg_primary_conninfo

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Magnus Hagander <magnus(at)hagander(dot)net>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_primary_conninfo
Date: 2010-12-28 14:58:28
Message-ID: 19080.1293548308@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Magnus Hagander <magnus(at)hagander(dot)net> writes:
> Attached patch implements a function called pg_primary_conninfo() that
> returns, well, the primary_conninfo used on the standby when in
> streaming replication mode (otherwise NULL).

> Objections?

What's the use case? And aren't there security reasons to NOT expose
that? It might contain a password for instance.

> + if (recptr.xlogid == 0 && recptr.xrecoff == 0 && conninfo[0] != '\0')
> + PG_RETURN_NULL();

This test seems a bit incoherent.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Magnus Hagander 2010-12-28 15:04:56 Re: pg_primary_conninfo
Previous Message Tom Lane 2010-12-28 14:53:59 Re: "writable CTEs"