impala-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gabor Kaszab (Code Review)" <ger...@cloudera.org>
Subject [Impala-ASF-CR] IMPALA-1144: Fix exception when CTRL+C on running query in Impala-shell
Date Wed, 15 Nov 2017 00:16:38 GMT
Gabor Kaszab has uploaded this change for review. ( http://gerrit.cloudera.org:8080/8549


Change subject: IMPALA-1144: Fix exception when CTRL+C on running query in Impala-shell
......................................................................

IMPALA-1144: Fix exception when CTRL+C on running query in Impala-shell

When query was cancelled via CTRL+C while Impala-shell was fetching the
query results then an exception was thrown from Impala backend saying
'Invalid query handle'.
This was because one ImpalaClient was fetching the result in a loop while
another ImpalaClient cancelled the query on the backend without letting the
fetching client know that the query was cancelled. As a result when the
resources needed for fetching the results were cleared from the backend
the related ClientRequestState was not found anymore.

As a solution query cancellation is indicated to ImpalaClient via a bool
member, and fetching stops if it indicates cancellation.

Another issue was that every time a query was cancelled a 'use db' command
was issued automatically. This happened to historical reasons but not needed
anymore (see Jira for more details).

Change-Id: I6cefaf1dae78baae238289816a7cb9d210fb38e2
---
M shell/impala_client.py
M shell/impala_shell.py
2 files changed, 6 insertions(+), 1 deletion(-)



  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/49/8549/1
-- 
To view, visit http://gerrit.cloudera.org:8080/8549
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I6cefaf1dae78baae238289816a7cb9d210fb38e2
Gerrit-Change-Number: 8549
Gerrit-PatchSet: 1
Gerrit-Owner: Gabor Kaszab <gaborkaszab@cloudera.com>

Mime
  • Unnamed multipart/alternative (inline, 8-Bit, 0 bytes)
View raw message