IMPALA-2309: Compute stats query return error if set LIVE_PROGRESS=true

Impala shell cannot get child query handle so it cannot
query live progress for COMPUTE STATS query. Disable live
progress callback for compute stats query.

Change-Id: I2d2f342a805905a4fa868686e7c9e9362c2c2223
Reviewed-on: http://gerrit.cloudera.org:8080/1109
Reviewed-by: Juan Yu <jyu@cloudera.com>
Tested-by: Internal Jenkins
This commit is contained in:
Juan Yu
2015-09-29 21:19:05 -07:00
committed by ishaan
parent 265bed6494
commit 0df3b419a0
2 changed files with 31 additions and 1 deletions

View File

@@ -78,6 +78,21 @@ class TestImpalaShellInteractive(object):
self._expect_with_cmd(proc, "set live_summary=1")
self._expect_with_cmd(proc, "set", ("LIVE_PROGRESS: True", "LIVE_SUMMARY: True"))
@pytest.mark.execute_serially
def test_compute_stats_with_live_progress_options(self):
"""Test that setting LIVE_PROGRESS options won't cause COMPUTE STATS query fail"""
impalad = ImpaladService(socket.getfqdn())
p = self._start_new_shell_process()
self._send_cmd_to_shell(p, "set live_progress=True")
self._send_cmd_to_shell(p, "set live_summary=True")
self._send_cmd_to_shell(p, 'create table test_live_progress_option(col int);')
try:
self._send_cmd_to_shell(p, 'compute stats test_live_progress_option;')
finally:
self._send_cmd_to_shell(p, 'drop table if exists test_live_progress_option;')
result = get_shell_cmd_result(p)
assert "Updated 1 partition(s) and 1 column(s)" in result.stdout
@pytest.mark.execute_serially
def test_escaped_quotes(self):
"""Test escaping quotes"""