diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2018-10-06 15:12:51 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2018-10-06 15:12:51 -0400 |
commit | f2343653f5b2aecfc759f36dbb3fd2a61f36853e (patch) | |
tree | 3e1fcb103bd838a0b3715b6e11a9e44d3f358f10 /src/backend/executor/nodeAppend.c | |
parent | 0209f0285d9b1c60bf74cc9f5f0133d7bdd887c3 (diff) | |
download | postgresql-f2343653f5b2aecfc759f36dbb3fd2a61f36853e.tar.gz postgresql-f2343653f5b2aecfc759f36dbb3fd2a61f36853e.zip |
Remove more redundant relation locking during executor startup.
We already have appropriate locks on every relation listed in the
query's rangetable before we reach the executor. Take the next step
in exploiting that knowledge by removing code that worries about
taking locks on non-leaf result relations in a partitioned table.
In particular, get rid of ExecLockNonLeafAppendTables and a stanza in
InitPlan that asserts we already have locks on certain such tables.
In passing, clean up some now-obsolete comments in InitPlan.
Amit Langote, reviewed by David Rowley and Jesper Pedersen,
and whacked around a bit more by me
Discussion: https://postgr.es/m/468c85d9-540e-66a2-1dde-fec2b741e688@lab.ntt.co.jp
Diffstat (limited to 'src/backend/executor/nodeAppend.c')
-rw-r--r-- | src/backend/executor/nodeAppend.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/src/backend/executor/nodeAppend.c b/src/backend/executor/nodeAppend.c index d44befd44e3..a16b6da4740 100644 --- a/src/backend/executor/nodeAppend.c +++ b/src/backend/executor/nodeAppend.c @@ -113,12 +113,6 @@ ExecInitAppend(Append *node, EState *estate, int eflags) Assert(!(eflags & EXEC_FLAG_MARK)); /* - * Lock the non-leaf tables in the partition tree controlled by this node. - * It's a no-op for non-partitioned parent tables. - */ - ExecLockNonLeafAppendTables(node->partitioned_rels, estate); - - /* * create new AppendState for our append node */ appendstate->ps.plan = (Plan *) node; |