Hello Csaba Ringhofer, Michael Smith, Impala Public Jenkins,

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/24702

to look at the new patch set (#4).

Change subject: IMPALA-15115: Fix race condition in GetOperationStatus with 
query retries
......................................................................

IMPALA-15115: Fix race condition in GetOperationStatus with query retries

GetOperationStatus() (and get_state() for beeswax) gets the
active query handle, waits for execution to complete, then
returns the status for that query handle. While this is
happening, the query could hit an error and get retried.
In that case, GetOperationStatus is still looking at the old
query handle that failed. It would return the failure even
though there is a new query handle for the retry.

Long polling waits for an extended time for execution to
complete, so it deterministically hits this issue.

This changes the logic so that it detects a retry, looks up the
new active handle, and returns the status from the new handle.
This applies to both HS2 and Beeswax.

Testing:
 - Added tests to test_query_retries.py with long polling for both
   HS2 and Beeswax

Change-Id: I9934a797650eec57b8280e6a6d2ef252dac00c69
---
M be/src/service/impala-beeswax-server.cc
M be/src/service/impala-hs2-server.cc
M be/src/service/impala-server.h
M tests/custom_cluster/test_query_retries.py
4 files changed, 174 insertions(+), 22 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/02/24702/4
--
To view, visit http://gerrit.cloudera.org:8080/24702
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I9934a797650eec57b8280e6a6d2ef252dac00c69
Gerrit-Change-Number: 24702
Gerrit-PatchSet: 4
Gerrit-Owner: Joe McDonnell <[email protected]>
Gerrit-Reviewer: Csaba Ringhofer <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Joe McDonnell <[email protected]>
Gerrit-Reviewer: Michael Smith <[email protected]>

Reply via email to