Add backendType to PGPROC, replacing isRegularBackend We can immediately make use of it in pg_signal_backend(), which previously fetched the process type from the backend status array with pgstat_get_backend_type_by_proc_number(). That was correct but felt a little questionable to me: backend status should be for observability purposes only, not for permission checks.
Reviewed-by: Nathan Bossart <[email protected]> Reviewed-by: Bertrand Drouvot <[email protected]> Reviewed-by: Chao Li <[email protected]> Discussion: https://www.postgresql.org/message-id/[email protected] Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/084e42bc7109673e46527b0a0f284edf539c3285 Modified Files -------------- src/backend/access/transam/twophase.c | 2 +- src/backend/storage/ipc/procarray.c | 4 ++-- src/backend/storage/ipc/signalfuncs.c | 5 +---- src/backend/storage/lmgr/proc.c | 4 ++-- src/backend/utils/activity/backend_status.c | 25 ------------------------- src/include/storage/proc.h | 5 +++-- src/include/utils/backend_status.h | 1 - 7 files changed, 9 insertions(+), 37 deletions(-)
