Lars Volker has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/12019 )
Change subject: IMPALA-6955: fix test_query_concurrency and server startup sequence ...................................................................... IMPALA-6955: fix test_query_concurrency and server startup sequence custom_cluster/test_query_concurrency created two threads to poll the query_plan debug webpage without joining them. Then they could outlive the test itself and continued to poll the webpage while the minicluster of the next test started up. During startup of the coordinator, the ImpalaServer would register its HTTP handlers with the webserver before registering itself with the ExecEnv. When the incoming request from the polling threads called GetClientRequestState(), that call would dereference a nullptr returned by the ExecEnv, which would cause the process to crash. To fix this we join the threads in test_query_concurrency before returning from the test method. To fix the underlying race that made the crash possible we change the initialization order to register the HTTP handlers after the ImpalaServer has been registered with the ExecEnv. We also add some DCHECKs to make sure that we access the ImpalaServer only through a singleton instance and that it is properly registered with the ExecEnv. Change-Id: If22f71ab6edaf9a6b46afc0985c73dc4625b5103 Reviewed-on: http://gerrit.cloudera.org:8080/12019 Reviewed-by: Impala Public Jenkins <[email protected]> Tested-by: Impala Public Jenkins <[email protected]> --- M be/src/runtime/exec-env.cc M be/src/runtime/exec-env.h M be/src/service/impala-server.cc M be/src/service/impala-server.h M tests/custom_cluster/test_query_concurrency.py 5 files changed, 27 insertions(+), 12 deletions(-) Approvals: Impala Public Jenkins: Looks good to me, approved; Verified -- To view, visit http://gerrit.cloudera.org:8080/12019 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: If22f71ab6edaf9a6b46afc0985c73dc4625b5103 Gerrit-Change-Number: 12019 Gerrit-PatchSet: 4 Gerrit-Owner: Lars Volker <[email protected]> Gerrit-Reviewer: Bharath Vissapragada <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Lars Volker <[email protected]> Gerrit-Reviewer: Michael Ho <[email protected]> Gerrit-Reviewer: Tim Armstrong <[email protected]>
