Commit Graph
3615 Commits
Author SHA1 Message Date
Hayden Stainsby 135d7ca38e taskdump: fix taskdump cargo config example (#6150)
The documentation for the `Handle::dump()` method includes a description
of the Rust flags needed. However, the sample `.cargo/config.toml` file
is incorrect. It gives the Rust flags as:

```
rustflags = ["--cfg tokio_unstable", "--cfg tokio_taskdump"]
```

However, each command line argument needs to be a separate element in
the array:

```
rustflags = ["--cfg", "tokio_unstable", "--cfg", "tokio_taskdump"]
```

This change corrects that line.
2023-11-14 20:17:05 +01:00
Alice Ryhl e6720f985d metrics: fix hang in worker_overflow_count test (#6146)
Closes: #6054
2023-11-14 20:13:56 +01:00
Alice Ryhl d44e995bb0 task: document cancel safety of LocalSet::run_until (#6147)
Closes: #6122
2023-11-14 20:13:43 +01:00
Alice Ryhl 06660ef00a io: flush in AsyncWriteExt examples (#6149)
Closes: #6068
2023-11-14 20:13:00 +01:00
Alice Ryhl 2e5773a6fe runtime: handle missing context on wake (#6148) 2023-11-14 14:01:10 +01:00
Carl Lerche 49eb26f159 chore: prepare Tokio v1.34.0 release (#6138)
This also includes:
  - tokio-macros v2.2.0
tokio-1.34.0 tokio-macros-2.2.0
2023-11-09 11:22:54 -08:00
Carl Lerche 19d96c0674 io: increase ScheduledIo tick resolution (#6135)
While this is no current evidence that increasing the tick resolution is
necessary, since we have available bits, we might as well use them.
2023-11-08 15:11:18 -08:00
Carl Lerche 30b2eb17c8 io: fix possible I/O resource hang (#6134)
Use a per-resource tick instead of a single global tick counter. This
prevents the hang issue described by #6133.

Fixes: #6133
2023-11-08 14:05:06 -08:00
aliu 8ec3e0d94d metrics: update stats when unparking in multi-thread (#6131) 2023-11-06 17:14:51 +01:00
Yotam Ofek 161ecec156 stream: fix typo in peekable docs (#6130) 2023-11-05 22:51:09 +01:00
Tymoteusz Wiśniewski 61fcc3bc0b time: remove cached elapsed value from driver state (#6097) 2023-11-05 15:00:05 +01:00
Alice Ryhl 944024e8eb chore: update rust-version to 1.63 in all crates (#6126) 2023-11-04 09:07:22 +01:00
ad hoc 65f861f478 stream: add StreamExt::peekable (#6095) 2023-11-01 17:32:35 +00:00
Alice Ryhl 4c8580152d ci: fix docs on latest nightly (#6120) 2023-11-01 16:33:32 +00:00
Hayden Stainsby ed32cd194c task: add tests for tracing instrumentation of tasks (#6112)
Tokio is instrumented with traces which can be used to analyze the
behavior of the runtime during execution or post-mortem. The
instrumentation is optional. This is where tokio-console collections
information.

There are currently no tests for the instrumentation.

In order to provide more stability to the instrumentation and prepare
for future changes, tests are added to verify the current behavior. The
tests are written using the `tracing-mock` crate. As this crate is still
unreleased, a separate test create has been added under `tokio/tests`
which is outside the workspace. This allows us to pull in both `tracing`
and `tracing-mock` from the tracing repository on GitHub without
affecting the rest of the tokio repository.

This change adds initial tests for the task instrumentation. Further
tests will be added in subsequent commits.

Once `tracing-mock` is published on crates.io (tokio-rs/tracing#539),
these tests can be moved in with the "normal" tokio integration tests.
The decision to add these tests now is due to the release of
`tracing-mock` taking a while, so it would be better to have tests while
we wait.
2023-10-31 10:02:00 +01:00
Fritz Rehde 593dbf55d1 docs: fix typos (#6118) 2023-10-30 15:17:46 +01:00
Satyam1Vishwakarma d8a4a5f24b tokio: gate some panicking tests with #[cfg(panic = "unwind")] (#6115) 2023-10-30 11:51:39 +01:00
Alice Ryhl cc86fef9c0 tokio: gate some panicking tests with #[cfg(panic = "unwind")] (#6110) 2023-10-26 12:28:12 +02:00
Nikolay Arhipov f3949cc56d tokio: added vita target support (#6094) 2023-10-25 14:44:41 +02:00
Alice Ryhl 503fad7908 chore: prepare tokio-util v0.7.10 (#6104) tokio-util-0.7.10 2023-10-25 12:05:47 +02:00
Alice Ryhl 58acb56a17 ci: update nightly to 2023-10-21 (#6103) 2023-10-24 14:15:25 +00:00
Friedel Ziegelmayer d22c549d97 deps: update hashbrown to 0.14 (#6102) 2023-10-24 12:27:39 +02:00
xianhua zhouandXianhua Zhou bc48a6fa8d sync: fix broadcast::channel link (#6100)
Co-authored-by: Xianhua Zhou <[email protected]>
2023-10-23 15:40:17 +00:00
Alice Ryhl 70410836ae task: add tokio_util::sync::TaskTracker (#6033) 2023-10-22 14:35:19 +00:00
Aaron Schweiger 881b510a07 sync: add mpsc::Receiver::recv_many (#6010) 2023-10-17 11:01:41 +02:00
Rafael Bachmann 6871084629 chore: clippy and doc fixes (#6081) 2023-10-16 17:37:51 +02:00
Alice Ryhl 1b8ebfcffb readme: remove rdbc and add axum to related projects (#6077) 2023-10-16 10:25:40 +02:00
Alice Ryhl 654a3d5acf io: fix integer overflow in take (#6080) 2023-10-15 20:54:27 +02:00
Alice Ryhl a08ad926b1 changelog: fix typo in quadratic (#6079) 2023-10-15 20:30:46 +02:00
Alice Ryhl 723934242b time: reorder comment in sleep.rs (#6076) 2023-10-15 19:21:57 +02:00
Alice Ryhl 944f769cd5 chore: remove bin directory (#6078) 2023-10-15 19:21:12 +02:00
inkyu f3ad6cffd9 task: fix missing wakeup when using LocalSet::enter (#6016) 2023-10-15 19:18:06 +02:00
Andrea StedileandAlice Ryhl f1e41a4ad4 task: add JoinMap::keys (#6046)
Co-authored-by: Alice Ryhl <[email protected]>
2023-10-15 16:47:41 +02:00
icedrocket f9335b8186 fs: update cfg attr in fs::read_dir (#6075) 2023-10-15 13:50:33 +02:00
Alice Ryhl 1134cbb168 net: fix flaky doctest for TcpStream::into_std (#6074) 2023-10-14 15:09:07 +00:00
Alice Ryhl 339c78a680 tokio: remove #5973 from changelog (#6073) 2023-10-14 12:24:45 +00:00
Tymoteusz Wiśniewski c00861210b chore: move 1.20.x to previous LTS releases (#6069) 2023-10-12 18:18:03 +02:00
Alice Ryhl 0f296d2089 io: allow clear_readiness after io driver shutdown (#6067) 2023-10-12 08:18:22 -07:00
Tymoteusz Wiśniewski d420d528f9 chore: render taskdump docs in Netlify previews (#6060) 2023-10-09 11:57:36 +02:00
Tymoteusz Wiśniewski 0457690d01 chore: prepare Tokio v1.33.0 release (#6059) tokio-1.33.0 2023-10-09 11:55:17 +02:00
David Yamnitsky 4557451257 io: implement Seek for SyncIoBridge (#6058) 2023-10-07 14:43:35 +02:00
Jack Wrenn 2bd43765d9 rt: do not trace tasks while locking OwnedTasks (#6036) 2023-10-06 21:48:47 +02:00
Dan Kov f306bd02c3 sync: fix unclosed code block in example (#6056) 2023-10-06 14:33:26 +02:00
Alice Ryhl 6b010ac80f docs: fix new doc warnings in 1.73.0 (#6055) 2023-10-06 09:49:44 +00:00
Alice Ryhl 8cd3383913 time: reduce iteration count in short_sleeps test (#6052) 2023-10-05 22:03:27 +00:00
Alice Ryhl d6ed00c292 sync: Semaphore doc final cleanup (#6050) 2023-10-05 12:43:49 +00:00
songmuhan 5d29136a83 docs: add semaphore example for running tests sequentially (#6038)
Signed-off-by: Muhan Song <[email protected]>
2023-10-05 13:48:19 +02:00
Luís Cruz 52b29b33bb net: add apple tvos support (#6045) 2023-10-04 18:48:53 +02:00
Alice Ryhl eaba9712e8 sync: document that broadcast capacity is a lower bound (#6042) 2023-10-03 07:58:34 +00:00
Alice Ryhl 310adf7ca6 rt: fix flaky test test_disable_lifo_slot (#6043) 2023-10-02 15:05:48 +02:00