MCPcopy Create free account
hub / github.com/apache/arrow / ScheduleTask

Method ScheduleTask

cpp/src/arrow/acero/query_context.cc:61–67  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

59}
60
61void QueryContext::ScheduleTask(std::function<Status()> fn, std::string_view name) {
62 ::arrow::internal::Executor* exec = executor();
63 // Adds a task which submits fn to the executor and tracks its progress. If we're
64 // already stopping then the task is ignored and fn is not executed.
65 async_scheduler_->AddSimpleTask(
66 [exec, fn = std::move(fn)]() mutable { return exec->Submit(std::move(fn)); }, name);
67}
68
69void QueryContext::ScheduleTask(std::function<Status(size_t)> fn, std::string_view name) {
70 std::function<Status()> indexed_fn = [this, fn]() {

Callers 9

HandleBatchMethod · 0.80
StartProducingMethod · 0.80
ScheduleTaskCallbackMethod · 0.80
DispatchMethod · 0.80
SendBatchesUnlockedMethod · 0.80
DoFinishMethod · 0.80
ScheduleMethod · 0.80
SliceAndDeliverMorselMethod · 0.80
ARROW_ASSIGN_OR_RAISEMethod · 0.80

Calls 1

executorFunction · 0.70

Tested by 2

DispatchMethod · 0.64
SendBatchesUnlockedMethod · 0.64