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

Method AdmissionStateMapCleanupLoop

be/src/scheduling/admission-control-service.cc:441–457  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

439}
440
441void AdmissionControlService::AdmissionStateMapCleanupLoop() {
442 std::unique_lock<std::mutex> lock(cleanup_queue_lock_);
443 while (true) {
444 cleanup_queue_cv_.wait(lock,
445 [&] { return !admission_state_cleanup_queue_.empty() || shutdown_.load(); });
446 if (admission_state_cleanup_queue_.empty() && shutdown_.load()) return;
447 std::deque<std::pair<UniqueIdPB, const char*>> local_queue;
448 std::swap(local_queue, admission_state_cleanup_queue_);
449 lock.unlock();
450 for (const auto& entry : local_queue) {
451 discard_result(admission_state_map_.Delete(entry.first));
452 VLOG_QUERY << "Cleaned up admission state map for query=" << PrintId(entry.first)
453 << ", triggered by function: " << entry.second;
454 }
455 lock.lock();
456 }
457}
458
459} // namespace impala

Callers

nothing calls this directly

Calls 8

discard_resultFunction · 0.85
PrintIdFunction · 0.85
waitMethod · 0.80
emptyMethod · 0.45
loadMethod · 0.45
unlockMethod · 0.45
DeleteMethod · 0.45
lockMethod · 0.45

Tested by

no test coverage detected