[Fix](executor) Fix insert select not close coordinator #32571

This commit is contained in:
wangbo
2024-03-21 13:56:04 +08:00
committed by yiguolei
parent 844dd8b2ce
commit 886aabda31
2 changed files with 6 additions and 1 deletions

View File

@ -172,6 +172,7 @@ public abstract class AbstractInsertExecutor {
onFail(t);
return;
} finally {
coordinator.close();
executor.updateProfile(true);
QeProcessorImpl.INSTANCE.unregisterQuery(ctx.queryId());
}

View File

@ -634,7 +634,11 @@ public class Coordinator implements CoordInterface {
@Override
public void close() {
if (queryQueue != null && queueToken != null) {
queryQueue.returnToken(queueToken);
try {
queryQueue.returnToken(queueToken);
} catch (Throwable t) {
LOG.error("error happens when coordinator close ", t);
}
}
}