Re: Pasword expiration warning

From: Nathan Bossart <nathandbossart(at)gmail(dot)com>
To: Zsolt Parragi <zsolt(dot)parragi(at)percona(dot)com>
Cc: Peter Eisentraut <peter(at)eisentraut(dot)org>, Gilles Darold <gilles(at)darold(dot)net>, Japin Li <japinli(at)hotmail(dot)com>, Yuefei Shi <shiyuefei1004(at)gmail(dot)com>, songjinzhou <tsinghualucky912(at)foxmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, liu xiaohui <liuxh(dot)zj(dot)cn(at)gmail(dot)com>, Steven Niu <niushiji(at)gmail(dot)com>
Subject: Re: Pasword expiration warning
Date: 2026-02-04 20:22:29
Message-ID: aYOqhR9fKC8hdir3@nathan
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Feb 04, 2026 at 05:44:06PM +0000, Zsolt Parragi wrote:
> Wouldn't that be more confusing?
>
> The password for role "foo" will expire at 2026-02-05 16:56"
>
> No matter which date format is used, this is harder to understand than
>
> The password for role "foo" will expire in 1 day(s)

Fair enough. The main problem we need to figure out for that approach is
how to handle plurals without "(s)". One option is to move the ereport()
to this function, but as before [0], I'm not sure we want to send a warning
before more of the initialization has completed. Another option could be
to add a new function that checks the expiration time and emits a warning
as needed, and call that at the end of InitPostgres().

[0] https://postgr.es/m/aYEJhk83XAqk76dP%40nathan

--
nathan

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Mark Wong 2026-02-04 20:22:40 Re: oid2name : add objects file path
Previous Message Sami Imseih 2026-02-04 20:15:02 Re: Flush some statistics within running transactions