When reaches to executor pool size, COPY sets the placement access

It looks like we forgot to set the placement accesses, and
this could lead to self-deadlocks on complex transaction blocks.

(cherry picked from commit 36bdeef1bb)
pull/5081/head
Onder Kalaci 2021-01-27 10:17:56 +01:00
parent d0000a15bd
commit 3065966d13
1 changed files with 6 additions and 0 deletions

View File

@ -3585,6 +3585,12 @@ CopyGetPlacementConnection(HTAB *connectionStateHash, ShardPlacement *placement,
*/
Assert(connection != NULL);
/*
* Make sure that the connection management remembers that Citus
* accesses this placement over the connection.
*/
AssignPlacementListToConnection(list_make1(placementAccess), connection);
return connection;
}