mapleFU commented on issue #43768:
URL: https://github.com/apache/arrow/issues/43768#issuecomment-2306132602
So this is because Acero call `consume` api directly in `ExecBatch`:
```c++
Status ScalarAggregateNode::DoConsume(const ExecSpan& batch, size_t
thread_index) {
for (size_t i = 0; i < kernels_.size(); ++i) {
arrow::util::tracing::Span span;
START_COMPUTE_SPAN(span, aggs_[i].function,
{{"function.name", aggs_[i].function},
{"function.options",
aggs_[i].options ? aggs_[i].options->ToString() :
"<NULLPTR>"},
{"function.kind", std::string(kind_name()) +
"::Consume"}});
KernelContext batch_ctx{plan()->query_context()->exec_context()};
DCHECK_LT(thread_index, states_[i].size());
batch_ctx.SetState(states_[i][thread_index].get());
std::vector<ExecValue> column_values;
for (const int field : target_fieldsets_[i]) {
column_values.push_back(batch.values[field]);
}
ExecSpan column_batch{std::move(column_values), batch.length};
RETURN_NOT_OK(kernels_[i]->consume(&batch_ctx, column_batch));
}
return Status::OK();
}
```
I've got this, thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]