Files
impala/tests/custom_cluster/test_query_retries.py
xqhe dfc2f175bd IMPALA-10414: fix memory leak when canceling the retried query
The query retry launches in a separate thread. This thread may not
finishes when deleting the query from the given QueryDriverMap if
the query retry was failed launched. In this case, the resources
for the query retry thread will not release. So the reference
count of QueryDriver (via the shared_ptr) will not go to 0 and it
will not be destroyed.

We need wait until the query retry thread execution has completed
when deleting the query from the given QueryDiverMap.

Testing:
Modify the test_query_retries.py to verify memory leak by checking
the debug web UI of memz.

Change-Id: If804ca65da1794c819a6b2e6567ea7651ab5112f
Reviewed-on: http://gerrit.cloudera.org:8080/17735
Reviewed-by: Wenzhe Zhou <wzhou@cloudera.com>
Tested-by: Impala Public Jenkins <impala-public-jenkins@cloudera.com>
Reviewed-by: Quanlong Huang <huangquanlong@gmail.com>
2022-04-15 01:36:59 +00:00

57 KiB