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

Method RegisterQueryLocations

be/src/service/impala-server.cc:2673–2690  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2671}
2672
2673void ImpalaServer::RegisterQueryLocations(
2674 const RepeatedPtrField<BackendExecParamsPB>& backend_params,
2675 const TUniqueId& query_id) {
2676 VLOG_QUERY << "Registering query locations";
2677 if (!backend_params.empty()) {
2678 lock_guard<mutex> l(query_locations_lock_);
2679 for (const BackendExecParamsPB& param : backend_params) {
2680 const BackendIdPB& backend_id = param.backend_id();
2681 auto it = query_locations_.find(backend_id);
2682 if (it == query_locations_.end()) {
2683 query_locations_.emplace(
2684 backend_id, QueryLocationInfo(param.address(), query_id));
2685 } else {
2686 it->second.query_ids.insert(query_id);
2687 }
2688 }
2689 }
2690}
2691
2692void ImpalaServer::CancelQueriesOnFailedBackends(
2693 const std::unordered_set<BackendIdPB>& current_membership) {

Callers 1

Calls 5

QueryLocationInfoClass · 0.85
emptyMethod · 0.45
findMethod · 0.45
endMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected