Re: Add 'worker_type' to pg_stat_subscription

Nathan Bossart <nathandbossart@gmail.com>

From: Nathan Bossart <nathandbossart@gmail.com>
To: Amit Kapila <amit.kapila16@gmail.com>
Cc: Peter Smith <smithpb2250@gmail.com>, Maxim Orlov <orlovmg@gmail.com>, Michael Paquier <michael@paquier.xyz>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2023-09-20T19:30:38Z
Lists: pgsql-hackers

Attachments

On Tue, Sep 19, 2023 at 08:36:35AM +0530, Amit Kapila wrote:
> I am of the opinion that worker_type should be 'apply' instead of
> 'leader apply' because even when it is a leader for parallel apply
> worker, it could perform individual transactions apply. For reference,
> I checked pg_stat_activity.backend_type, there is nothing called main
> or leader backend even when the backend is involved in parallel query.

Okay.  Here is v9 of the patch with this change.

-- 
Nathan Bossart
Amazon Web Services: https://aws.amazon.com

Commits

  1. Add worker type to pg_stat_subscription.

  2. Simplify determining logical replication worker types.