tokio/tokio-current-thread
Jon Gjengset 0745a9b88a Use spawn_local to spawn from local Handles (#565)
Previously, every call to `current_thread::Handle::spawn` would go
through a `mpsc` channel. This is unnecessary when the `Handle` is still
on the same thread as the current thread executor. This patch fixes that
by storing the `ThreadId` of the executor when it is created, and then
comparing against that when `Handle::spawn` is called. If the call is
made from the same thread, `spawn_local` is used directly.

Fixes #562.
2018-08-30 11:24:59 -07:00
..
2018-08-25 15:26:41 -04:00
2018-08-06 20:36:50 -07:00
2018-08-06 20:36:50 -07:00
2018-06-12 10:26:03 -07:00
2018-06-12 10:26:03 -07:00

tokio-current-thread

Single threaded executor for Tokio.

Documentation

Overview

This crate provides the single threaded executor which execute many tasks concurrently.

License

This project is licensed under the MIT license.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Tokio by you, shall be licensed as MIT, without any additional terms or conditions.