MCPcopy Create free account
hub / github.com/apache/impala / Exec

Method Exec

be/src/service/client-request-state.cc:267–406  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

265}
266
267Status ClientRequestState::Exec() {
268 const TExecRequest& exec_req = exec_request();
269 profile_->AddChild(server_profile_);
270 summary_profile_->AddInfoString("Query Type", PrintValue(stmt_type()));
271 summary_profile_->AddInfoString("Query Options (set by configuration)",
272 DebugQueryOptions(query_ctx_.client_request.query_options));
273 summary_profile_->AddInfoString("Query Options (set by configuration and planner)",
274 DebugQueryOptions(exec_req.query_options));
275 if (!exec_req.tables.empty()) {
276 summary_profile_->AddInfoString("Tables Queried", PrintTableList(exec_req.tables));
277 }
278 if (!exec_req.select_columns.empty()) {
279 summary_profile_->AddInfoString("Select Columns", join(exec_req.select_columns, ","));
280 }
281 if (!exec_req.where_columns.empty()) {
282 summary_profile_->AddInfoString("Where Columns", join(exec_req.where_columns, ","));
283 }
284 if (!exec_req.join_columns.empty()) {
285 summary_profile_->AddInfoString("Join Columns", join(exec_req.join_columns, ","));
286 }
287 if (!exec_req.aggregate_columns.empty()) {
288 summary_profile_->AddInfoString(
289 "Aggregate Columns", join(exec_req.aggregate_columns, ","));
290 }
291 if (!exec_req.orderby_columns.empty()) {
292 summary_profile_->AddInfoString(
293 "OrderBy Columns", join(exec_req.orderby_columns, ","));
294 }
295 if (query_ctx_.__isset.overridden_mt_dop_value) {
296 DCHECK(query_ctx_.client_request.query_options.__isset.mt_dop);
297 summary_profile_->AddInfoString("MT_DOP limited by admission control",
298 Substitute("Requested MT_DOP=$0 reduced to MT_DOP=$1",
299 query_ctx_.overridden_mt_dop_value,
300 query_ctx_.client_request.query_options.mt_dop));
301 }
302
303 // Don't start executing the query if Cancel() was called between planning and Exec().
304 RETURN_IF_CANCELLED(this);
305 MarkActive();
306
307 switch (exec_req.stmt_type) {
308 case TStmtType::QUERY:
309 case TStmtType::DML:
310 DCHECK(exec_req.__isset.query_exec_request);
311 RETURN_IF_ERROR(
312 ExecQueryOrDmlRequest(exec_req.query_exec_request, true /*async*/));
313 break;
314 case TStmtType::EXPLAIN: {
315 request_result_set_.reset(new vector<TResultRow>(
316 exec_req.explain_result.results));
317 break;
318 }
319 case TStmtType::TESTCASE: {
320 DCHECK(exec_req.__isset.testcase_data_path);
321 SetResultSet(vector<string>(1, exec_req.testcase_data_path));
322 break;
323 }
324 case TStmtType::DDL: {

Callers 4

ExecDdlRequestImplMethod · 0.45
ExecuteMetadataOpMethod · 0.45
ExecuteInternalMethod · 0.45

Calls 15

PrintValueFunction · 0.85
PrintTableListFunction · 0.85
joinFunction · 0.85
SubstituteFunction · 0.85
iequalsFunction · 0.85
UnixMillisFunction · 0.85
OKFunction · 0.85
AddChildMethod · 0.80
AddInfoStringMethod · 0.80
UpdateTimeoutMethod · 0.80

Tested by

no test coverage detected