sanjibansg commented on a change in pull request #12720:
URL: https://github.com/apache/arrow/pull/12720#discussion_r837980845
##########
File path: cpp/src/arrow/compute/exec/exec_plan.cc
##########
@@ -436,22 +436,11 @@ void
MapNode::SubmitTask(std::function<Result<ExecBatch>(ExecBatch)> map_fn,
return Status::OK();
};
- if (executor_) {
- status = task_group_.AddTask([this, task]() -> Result<Future<>> {
- return this->executor_->Submit(this->stop_source_.token(), [this,
task]() {
- auto status = task();
- if (this->input_counter_.Increment()) {
- this->Finish(status);
- }
- return status;
- });
- });
- } else {
- status = task();
- if (input_counter_.Increment()) {
- this->Finish(status);
- }
+ status = task();
+ if (input_counter_.Increment()) {
+ this->Finish(status);
}
+
// If we get a cancelled status from AddTask it means this node was stopped
// or errored out already so we can just drop the task.
if (!status.ok() && !status.IsCancelled()) {
Review comment:
Made the change.
--
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]