Illegally killing a JDBC select query causes locking problems
#include "tcop/pquery.h" /* PortalGetResource */
#include "resourcemanager/communication/rmcomm_QD2RM.h"
+#include "storage/ipc.h"
/* Define and structure */
typedef struct DispatchTask
@@ -1414,11 +1415,14 @@ dispatch_cleanup(DispatchData *data)
if (dispatcher_is_state_error(data))
{
/* We cannot unbind executors until we retrieve error message! */
+ if (!proc_exit_inprogress) {
dispatch_throw_error(data);
Assert(false);
return; /* should not hit */
}
+ }
+
dispatch_end_env(data);
}
