Philip Zeyliger has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/8549 )

Change subject: IMPALA-1144: Fix exception when cancelling query in 
Impala-shell with CTRL-C
......................................................................


Patch Set 3:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/8549/2//COMMIT_MSG
Commit Message:

http://gerrit.cloudera.org:8080/#/c/8549/2//COMMIT_MSG@25
PS2, Line 25: Tested manually starting with a select from a random table that 
has few
> I haven't figured out a way to test this automatically.
So, um, if you want a query that returns a lot of rows:

 with v as (values (1 as x), (2), (3), (4)) select * from v, v v2, v v3, v v4, 
v v5, v v6, v v7, v v8, v v9

will do it. (Customize as necessary.)

In my very quick experiment, that query is long enough that Ctrl-C worked (but 
got the query handle error), and, um, takes 20 seconds to go to /dev/null, so 
you've got time to try the cancellation.

$impala-shell.sh --query ' with v as (values (1 as x), (2), (3), (4)) select * 
from v, v v2, v v3, v v4, v v5, v v6, v v7, v v8, v v9' -o /dev/null
Starting Impala Shell without Kerberos authentication
Connected to localhost:21000
Server version: impalad version 2.11.0-SNAPSHOT DEBUG (build 
454a4aefa426725ab8806cfc814fb8e9df3ab8e5)
Query: with v as (values (1 as x), (2), (3), (4)) select * from v, v v2, v v3, 
v v4, v v5, v v6, v v7, v v8, v v9
Fetched 262144 row(s) in 21.50s

$impala-shell.sh --query ' with v as (values (1 as x), (2), (3), (4)) select * 
from v, v v2, v v3, v v4, v v5, v v6, v v7, v v8, v v9' -o /dev/null
Starting Impala Shell without Kerberos authentication
Connected to localhost:21000
Server version: impalad version 2.11.0-SNAPSHOT DEBUG (build 
454a4aefa426725ab8806cfc814fb8e9df3ab8e5)
Query: with v as (values (1 as x), (2), (3), (4)) select * from v, v v2, v v3, 
v v4, v v5, v v6, v v7, v v8, v v9
^C Cancelling Query
ERROR: Invalid query handle: 864b2a5cd241853b:c45bb8fe00000000

Could not execute command: with v as (values (1 as x), (2), (3), (4)) select * 
from v, v v2, v v3, v v4, v v5, v v6, v v7, v v8, v v9


Note that I didn't get "Invalid query handle" every time; depends a little bit 
on the timing of Ctrl-C.



--
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: comment
Gerrit-Change-Id: I6cefaf1dae78baae238289816a7cb9d210fb38e2
Gerrit-Change-Number: 8549
Gerrit-PatchSet: 3
Gerrit-Owner: Gabor Kaszab <[email protected]>
Gerrit-Reviewer: Attila Jeges <[email protected]>
Gerrit-Reviewer: Csaba Ringhofer <[email protected]>
Gerrit-Reviewer: Dan Hecht <[email protected]>
Gerrit-Reviewer: David Knupp <[email protected]>
Gerrit-Reviewer: Gabor Kaszab <[email protected]>
Gerrit-Reviewer: Lars Volker <[email protected]>
Gerrit-Reviewer: Laszlo Gaal <[email protected]>
Gerrit-Reviewer: Michael Brown <[email protected]>
Gerrit-Reviewer: Philip Zeyliger <[email protected]>
Gerrit-Reviewer: Tim Armstrong <[email protected]>
Gerrit-Reviewer: Zoltan Borok-Nagy <[email protected]>
Gerrit-Comment-Date: Wed, 15 Nov 2017 05:03:45 +0000
Gerrit-HasComments: Yes

Reply via email to