Replace job cancellation call with DirectFunctionCall for improved error handling

m3hm3t/issue_7896
Mehmet Yilmaz 2025-04-04 11:09:32 +00:00
parent 85a1c730ce
commit 62ef1c3536
1 changed files with 1 additions and 1 deletions

View File

@ -343,7 +343,7 @@ citus_job_wait_internal(int64 jobid, BackgroundJobStatus *desiredStatus)
MemoryContextSwitchTo(TopMemoryContext);
/* Attempt to cancel the job; if it's already in a terminal state, that's okay. */
citus_cancel_job(jobid);
(void) DirectFunctionCall1(citus_job_cancel, Int64GetDatum(jobid));
/* Re-throw the original error so Postgres knows this statement was canceled. */
PG_RE_THROW();