Re: [Patch] New psql prompt substitution %r (m = master, r = replica) - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: [Patch] New psql prompt substitution %r (m = master, r = replica)
Date
Msg-id 4b3b4e12-0647-1c91-e1e9-820529877549@2ndquadrant.com
Whole thread Raw
In response to [Patch] New psql prompt substitution %r (m = master, r = replica)  (Aleksander Alekseev <a.alekseev@postgrespro.ru>)
Responses Re: [Patch] New psql prompt substitution %r (m = master, r = replica)
List pgsql-hackers
On 8/11/16 6:04 AM, Aleksander Alekseev wrote:
> Suggested patch introduces an %r substitution in psql's prompt. This
> substitution allows to display whether user is connected to master or
> replica right in a prompt.

In the near future, there will (probably) be a lot more variants about
what it means to be a master or a replica.  There will be logical
replication, where you could be a publisher of something and a consumer
of something else.  You could even be a logical consumer but a physical
master.  So a global binary facility is probably not very forward
looking and will lead to confusion.

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



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: No longer possible to query catalogs for index capabilities?
Next
From: Tom Lane
Date:
Subject: Re: [Patch] New psql prompt substitution %r (m = master, r = replica)