| 267 | } |
| 268 | |
| 269 | Status StopProducing() override { |
| 270 | // GH-35837: ensure node is not paused |
| 271 | Future<> to_finish; |
| 272 | { |
| 273 | std::lock_guard<std::mutex> lg(mutex_); |
| 274 | if (!backpressure_future_.is_finished()) { |
| 275 | to_finish = backpressure_future_; |
| 276 | backpressure_future_ = Future<>::MakeFinished(); |
| 277 | } |
| 278 | } |
| 279 | if (to_finish.is_valid()) { |
| 280 | to_finish.MarkFinished(); |
| 281 | } |
| 282 | // only then stop |
| 283 | return ExecNode::StopProducing(); |
| 284 | } |
| 285 | |
| 286 | Status StopProducingImpl() override { |
| 287 | std::unique_lock<std::mutex> lock(mutex_); |
nothing calls this directly
no test coverage detected