From 9555cc8d2b02c4191d67ba39f589b39b01735518 Mon Sep 17 00:00:00 2001 From: Michael Paquier Date: Wed, 2 Oct 2019 09:55:27 +0900 Subject: Revert hooks for session start and end, take two The location of the session end hook has been chosen so as it is possible to allow modules to do their own transactions, however any trying to any any subsystem which went through before_shmem_exit() would cause issues, limiting the pluggability of the hook. Per discussion with Tom Lane and Andres Freund. Discussion: https://postgr.es/m/18722.1569906636@sss.pgh.pa.us --- src/backend/tcop/postgres.c | 6 ------ 1 file changed, 6 deletions(-) (limited to 'src/backend/tcop/postgres.c') diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c index 6d80cc2d64d..e8d8e6f8285 100644 --- a/src/backend/tcop/postgres.c +++ b/src/backend/tcop/postgres.c @@ -171,9 +171,6 @@ static ProcSignalReason RecoveryConflictReason; static MemoryContext row_description_context = NULL; static StringInfoData row_description_buf; -/* Hook for plugins to get control at start of session */ -session_start_hook_type session_start_hook = NULL; - /* ---------------------------------------------------------------- * decls for routines only used in this file * ---------------------------------------------------------------- @@ -3971,9 +3968,6 @@ PostgresMain(int argc, char *argv[], if (!IsUnderPostmaster) PgStartTime = GetCurrentTimestamp(); - if (session_start_hook) - (*session_start_hook) (); - /* * POSTGRES main processing loop begins here * -- cgit v1.2.3