Rename Function: pg_postmaster_start_time

From: Maiquel Grassi <grassi(at)hotmail(dot)com(dot)br>
To: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Rename Function: pg_postmaster_start_time
Date: 2024-11-05 18:26:31
Message-ID: CP4P284MB196806E4470A7B68C96937DCEC522@CP4P284MB1968.BRAP284.PROD.OUTLOOK.COM
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi!

I have been working on some servers that haven't been shut down or restarted for many days. As a result, the need arose to use the function 'pg_postmaster_start_time' (which I had completely forgotten existed).

While working with it, I realized that it would be more appropriate for its name to be 'pg_postgres_start_time', to align with the name of the main process displayed by the operating system. The process, which was previously known as "postmaster," has long been referred to as "postgres".

I suggest this change to simplify the terminology and make the function name more intuitive, as "postgres" directly refers to the database server. This seems more suitable to me.
Attached is the patch with the suggest adjustment.

Result:

[postgres(at)192 bin]$ pwd
/pgsql18devel/18devel_bin/bin
[postgres(at)192 bin]$ ./psql -p 5454 -h ::1
psql (18devel)
Type "help" for help.

postgres=# select pg_postgres_start_time();
pg_postgres_start_time
-------------------------------
2024-11-05 14:52:42.463293-03
(1 row)

Regards,
Maiquel Grassi.

Attachment Content-Type Size
v1-0001-Rename-pg_postmaster_start_time_function.patch text/x-patch 1.9 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2024-11-05 18:30:25 Re: Proposals for EXPLAIN: rename ANALYZE to EXECUTE and extend VERBOSE
Previous Message Nikolay Samokhvalov 2024-11-05 18:24:36 Re: Proposals for EXPLAIN: rename ANALYZE to EXECUTE and extend VERBOSE