tokio-rs / tokio

A runtime for writing reliable asynchronous applications with Rust. Provides I/O, networking, scheduling, timers, ...
https://tokio.rs
MIT License
26.59k stars 2.45k forks source link

feat: add spawn_blocking and spawn_blocking_on to the JoinSet builder #6578

Closed Rustin170506 closed 4 months ago

Rustin170506 commented 4 months ago

Motivation

close https://github.com/tokio-rs/tokio/issues/6565

Solution

  1. Added the spawn_blocking API to the builder.
  2. Added the spawn_blocking_on API to the builder.
Rustin170506 commented 4 months ago

Thanks for your review! 💚 💙 💜 💛 ❤️