From f1ae664910d6cbcf327e126f8bc96f4b8dabb13b Mon Sep 17 00:00:00 2001 From: odone Date: Mon, 23 Aug 2021 14:05:54 +0800 Subject: [PATCH] [KYUUBI #961] Fixed: opHanle's operation may not be release Align with `sessionManager.operationManager.closeOperation(operationHandle)` and remove first ### _Why are the changes needed?_ ### _How was this patch tested?_ - [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible - [ ] Add screenshots for manual tests if appropriate - [ ] [Run test](https://kyuubi.readthedocs.io/en/latest/develop_tools/testing.html#running-tests) locally before make a pull request Closes #975 from iodone/fix-opHanle-operation-not-release. Closes #961 bd798e0d [odone] [KYUUBI #961] fixed: opHanle's operation may not be release Authored-by: odone Signed-off-by: Cheng Pan --- .../main/scala/org/apache/kyuubi/session/AbstractSession.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kyuubi-common/src/main/scala/org/apache/kyuubi/session/AbstractSession.scala b/kyuubi-common/src/main/scala/org/apache/kyuubi/session/AbstractSession.scala index e2281821d..700316d35 100644 --- a/kyuubi-common/src/main/scala/org/apache/kyuubi/session/AbstractSession.scala +++ b/kyuubi-common/src/main/scala/org/apache/kyuubi/session/AbstractSession.scala @@ -178,8 +178,8 @@ abstract class AbstractSession( } override def closeOperation(operationHandle: OperationHandle): Unit = withAcquireRelease() { - sessionManager.operationManager.closeOperation(operationHandle) opHandleSet.remove(operationHandle) + sessionManager.operationManager.closeOperation(operationHandle) } override def getResultSetMetadata(