Re: Design of pg_stat_subscription_workers vs pgstats - Mailing list pgsql-hackers

From Masahiko Sawada
Subject Re: Design of pg_stat_subscription_workers vs pgstats
Date
Msg-id CAD21AoAtrgBEUU08VvfzRnGS+=9rS=MEq1cTLaZ1OT51xX34dQ@mail.gmail.com
Whole thread Raw
In response to Re: Design of pg_stat_subscription_workers vs pgstats  (Amit Kapila <amit.kapila16@gmail.com>)
Responses Re: Design of pg_stat_subscription_workers vs pgstats  (Amit Kapila <amit.kapila16@gmail.com>)
RE: Design of pg_stat_subscription_workers vs pgstats  ("osumi.takamichi@fujitsu.com" <osumi.takamichi@fujitsu.com>)
Re: Design of pg_stat_subscription_workers vs pgstats  (Andres Freund <andres@anarazel.de>)
RE: Design of pg_stat_subscription_workers vs pgstats  ("tanghy.fnst@fujitsu.com" <tanghy.fnst@fujitsu.com>)
Re: Design of pg_stat_subscription_workers vs pgstats  (Peter Smith <smithpb2250@gmail.com>)
List pgsql-hackers
On Mon, Feb 21, 2022 at 6:19 PM Amit Kapila <amit.kapila16@gmail.com> wrote:
>
> On Mon, Feb 21, 2022 at 1:18 PM Andres Freund <andres@anarazel.de> wrote:
> >
> > On 2022-02-21 12:39:31 +0530, Amit Kapila wrote:
> > > Fair enough. Then, how about the following keeping the following information:
> >
> > Mostly sounds good.
> >
> >
> > > * subid (subscription id)
> > > * subname (subscription name)
> >
> > Coming from catalog, via join, I assume?
> >
>
> The subname would be from pg_subscription catalog similar to what we
> are doing now for pg_stat_subscription_workers.

I've attached a patch that changes pg_stat_subscription_workers view.
It removes non-cumulative values such as error details such as
error-XID and the error message from the view, and consequently the
view now has only cumulative statistics counters: apply_error_count
and sync_error_count. Since the new view name is under discussion I
temporarily chose pg_stat_subscription_activity.

Regards,

-- 
Masahiko Sawada
EDB:  https://www.enterprisedb.com/

Attachment

pgsql-hackers by date:

Previous
From: "kuroda.hayato@fujitsu.com"
Date:
Subject: RE: [Proposal] Add foreign-server health checks infrastructure
Next
From: Peter Smith
Date:
Subject: Re: Optionally automatically disable logical replication subscriptions on error