Re: Support reset of Shared objects statistics in "pg_stat_reset" function

From: Sadhuprasad Patro <b(dot)sadhu(at)gmail(dot)com>
To: Mahendra Singh Thalor <mahi6run(at)gmail(dot)com>
Cc: Dilip Kumar <dilipbalaut(at)gmail(dot)com>, Himanshu Upadhyaya <upadhyaya(dot)himanshu(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Support reset of Shared objects statistics in "pg_stat_reset" function
Date: 2021-08-10 16:23:22
Message-ID: CAFF0-CGG0KjCcVevzkqg09j3V9rO-iAgywrw_HqDjT+C8EAJjw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> As of now, we are adding handling inside pg_stat_reset for shared
> tables but I think we can add a new function with the name of
> pg_stat_reset_shared_tables to reset stats for all the shared tables.
> New function will give more clarity to the users also. We already have
> a pg_stat_reset_shared(text) function for "archiver", "bgwriter", or
> "wal".
>
> Thoughts?

In my opinion, it is better to extend the functionality of
"pg_stat_reset" call because a new function just to reset shared table
data may not be needed. Where we already have a reset shared function
"pg_stat_reset_shared" in place.

All of applicable comments are implemented in the patch below:

Thanks & Regards
SadhuPrasad
EnterpriseDB: http://www.enterprisedb.com

Attachment Content-Type Size
v2-0001-DB-1318-pg_stat_reset-and-pg_stat_reset_single_ta.patch application/octet-stream 3.2 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Mahendra Singh Thalor 2021-08-10 17:02:14 Re: Support reset of Shared objects statistics in "pg_stat_reset" function
Previous Message Sadhuprasad Patro 2021-08-10 16:03:33 Re: Support reset of Shared objects statistics in "pg_stat_reset" function