MCPcopy Create free account
hub / github.com/apache/brpc / GetAnAssignment

Method GetAnAssignment

test/condition_variable_unittest.cc:502–510  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

500}
501
502TimeDelta WorkQueue::GetAnAssignment(int thread_id) {
503 DFAKE_SCOPED_RECURSIVE_LOCK(locked_methods_);
504 DCHECK_LT(0, task_count_);
505 assignment_history_[thread_id]++;
506 if (0 == --task_count_) {
507 no_more_tasks_.Signal();
508 }
509 return worker_delay_;
510}
511
512void WorkQueue::WorkIsCompleted(int thread_id) {
513 DFAKE_SCOPED_RECURSIVE_LOCK(locked_methods_);

Callers

nothing calls this directly

Calls 1

SignalMethod · 0.45

Tested by

no test coverage detected