stuhood commented on issue #13692: URL: https://github.com/apache/datafusion/issues/13692#issuecomment-4389775645
> I think block_in_place takes over one of the threads and prevents it from handling any more work until the blocking task is done. Yes. > For example if you have 8 threads in your Runtime you can only issue 8 block_in_place calls before no additional tasks can be processed I don't think so. My understanding is that when `block_in_place` blocks, it takes up one of the [max_blocking_thread](https://docs.rs/tokio/latest/tokio/runtime/struct.Builder.html#method.max_blocking_threads) slots, but the runtime will ensure that at least [worker_threads](https://docs.rs/tokio/latest/tokio/runtime/struct.Builder.html#method.worker_threads) are available for async work to continue running tasks. Note that the default for `max_blocking_threads` is 512, because I think that it _is_ true that you can deadlock if you run out of blocking thread slots. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
