Reuse SendCommandListToWorkerInSeparateTransaction inside SendCommandListToWorkerOutsideTransaction

reuse-connections-for-logical-ref-fkeys-2
Onder Kalaci 2022-09-14 17:55:07 +03:00
parent a5aaa08a20
commit 708a5829f5
1 changed files with 1 additions and 11 deletions

View File

@ -340,17 +340,7 @@ SendCommandListToWorkerOutsideTransaction(const char *nodeName, int32 nodePort,
nodeName, nodePort,
nodeUser, NULL);
MarkRemoteTransactionCritical(workerConnection);
RemoteTransactionBegin(workerConnection);
/* iterate over the commands and execute them in the same connection */
const char *commandString = NULL;
foreach_ptr(commandString, commandList)
{
ExecuteCriticalRemoteCommand(workerConnection, commandString);
}
RemoteTransactionCommit(workerConnection);
SendCommandListToWorkerInSeparateTransaction(workerConnection, commandList);
CloseConnection(workerConnection);
}