Re: Add %r substitution for psql prompts to show recovery status

From: Tatsuo Ishii <ishii(at)sraoss(dot)co(dot)jp>
To: a(dot)korotkov(at)postgrespro(dot)ru
Cc: ishii(at)sraoss(dot)co(dot)jp, robertmhaas(at)gmail(dot)com, ian(dot)barwick(at)2ndquadrant(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Add %r substitution for psql prompts to show recovery status
Date: 2017-12-13 04:17:25
Message-ID: 20171213.131725.779835663362595919.t-ishii@sraoss.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

>> Yeah. I think we need some from help backend for this. For example, a
>> parameter status message can be used here. If PostgreSQL moves to the
>> recovery state or vice versa, PostgreSQL sends the parameter status
>> message to frontend.
>>
>
> If we would use parameter status messages, then can we handle compatibility
> correctly? So that new psql can work with old backend without errors (and
> without recovery status display, for sure),

I suppose so.

> and old psql can work with new
> backend without errors.

It should work because any frontend program should ignore parameter
status messages they do not know, according to the docs.

> Because seeing recovery status in psql prompt is very neat. But execution
> of extra query each time doesn't seem like reasonable price for it...

I think so.

Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Munro 2017-12-13 04:30:51 Re: [HACKERS] SERIALIZABLE with parallel query
Previous Message Michael Paquier 2017-12-13 04:10:01 Re: Using ProcSignal to get memory context stats from a running backend