Commit Graph
3823 Commits
Author SHA1 Message Date
Alice Ryhl 68d0e3cb5f metrics: rename num_active_tasks to num_alive_tasks (#6667) 2024-06-30 15:02:29 +02:00
Tobias Nießen 65d0e08d39 runtime: fix typo in unhandled_panic (#6660) 2024-06-28 01:10:14 +09:00
Hai-Hsin 06582776a5 codec: fix length_delimited docs examples (#6638) 2024-06-23 13:52:51 +09:00
Eric Seppanen ed4ddf443d io: fix trait bounds on impl Sink for StreamReader (#6647)
This impl had a bound on `StreamReader<S, E>`; this is incorrect
because:
- The second generic parameter to `StreamReader` is not an error type;
  it's a buffer type.
- The `Stream` error type in `StreamReader` should not need to be the
  same as the `Sink` error type.

This "passthrough" `Sink` impl was effectively unusable because it
required the `Sink` error type be the same as the `StreamReader` buffer
type.

Resolve this by allowing the `StreamReader` buffer to be anything in
this impl.
2024-06-21 15:00:33 +02:00
Alice Ryhl 9a75d6f7f7 metrics: use MetricAtomic* for task counters (#6624) 2024-06-17 08:33:08 +00:00
Uwe Klotz 3bf4f93854 sync: add watch::Sender::same_channel (#6637) 2024-06-15 21:11:35 +02:00
FabijanC 39cf6bba00 macros: typo fix in join.rs and try_join.rs (#6641) 2024-06-15 21:10:47 +02:00
Weijia Jiang 8480a180e6 time: avoid traversing entries in the time wheel twice (#6584) 2024-06-14 11:03:47 +02:00
Timo 53ea44bfb9 sync: add CancellationToken::run_until_cancelled (#6618) 2024-06-13 10:58:45 +02:00
Weijia Jiang a865ca139a rt: relaxed trait bounds for LinkedList::into_guarded (#6630) 2024-06-13 08:50:28 +02:00
Niki C 479f736935 io: improve panic message of ReadBuf::put_slice() (#6629) 2024-06-13 01:09:59 +09:00
Marek Kuskowski 17555d71d9 sync: implement Default for watch::Sender (#6626) 2024-06-10 10:44:45 +02:00
Conrad Ludgate 341b5daa6e metrics: add spawned_tasks_count, rename active_tasks_count (#6114) 2024-06-09 12:25:54 +02:00
Rob Ede 53b586c5b9 task: stabilize consume_budget (#6622) 2024-06-08 22:17:06 +02:00
Hai-Hsin 833ee027d0 macros: allow unhandled_panic behavior for #[tokio::main] and #[tokio::test] (#6593) 2024-06-07 20:48:56 +09:00
Aaron Schweiger 126ce89bb4 task: implement Clone for AbortHandle (#6621) 2024-06-07 09:17:25 +02:00
Russell Cohen 8e15c234c6 metrics: add MetricAtomicUsize for usized-metrics (#6598) 2024-06-06 10:08:46 +02:00
John-John Tedro 16fccafb41 docs: fix docsrs builds with the fs feature enabled (#6585) 2024-06-05 08:20:27 +00:00
Armillus 3f397ccded io: read during write in copy_bidirectional and copy (#6532) 2024-06-05 00:29:28 +02:00
Emil Loer 49609d073f test: make Spawn forward size_hint (#6607) 2024-06-04 23:42:42 +02:00
Alan Somers a91d43823c ci: update FreeBSD CI environment (#6616)
Use the newly released FreeBSD 14.1.
2024-06-04 23:37:13 +02:00
Timo 8fca6f6dad process: add Command::as_std_mut (#6608) 2024-06-04 13:34:22 +02:00
Weijia Jiang 75c953bd63 time: fix big time panic issue (#6612) 2024-06-04 09:45:35 +02:00
Alice Ryhl 14c17fc096 chore: prepare Tokio v1.38.0 (#6601) tokio-1.38.0 2024-05-30 13:24:58 -07:00
Alice Ryhl 65cbf730de chore: prepare tokio-macros v2.3.0 (#6600) tokio-macros-2.3.0 2024-05-30 13:21:51 -07:00
Alice Ryhl dbf93c7184 sync: fix incorrect is_empty on mpsc block boundaries (#6603) 2024-05-30 13:21:16 -07:00
Weijia Jiang 873cb8ae2f runtime: move task out of the lifo_slot in block_in_place (#6596) 2024-05-30 10:45:45 +02:00
SteveLauC 97bb47b480 task: fix a typo in doc of LocalSet::run_until (#6599) 2024-05-30 10:44:53 +02:00
Russell Cohen 86658bd87d metrics: stabilize RuntimeMetrics::worker_count (#6556) 2024-05-28 21:55:20 +02:00
Pau Freixes 9e00b266e0 sync: add Notify::notify_last (#6520) 2024-05-27 11:18:34 +00:00
Maxwell Borden 6c42d286b3 net: fix misleading NamedPipeServer example (#6590)
The previous NamedPipeServer doc example seemed to imply that the return
type of `NamedPipeServer::connect()` was a
`Future<Result<some_kind_of_client>>>`, however, `connect()` returns a
`Future<Result<()>>>`. The following line of code reopening the pipe
would shadow the newly connected pipe immediately, making the following
spawned task pointless. Hopefully these changes make it more clear what
should be happening in the example.
2024-05-26 12:25:19 +02:00
Josh McKinney 3a6fdc0568 license: fix formatting and remove year in licenses (#6451) 2024-05-26 09:29:27 +00:00
Conrad Ludgate 2890d0c3db metrics: fix blocking_threads count (#6551) 2024-05-25 21:49:17 +00:00
Maxwell Borden 0a85a9662d net: implement Clone for NamedPipeInfo (#6586) 2024-05-25 22:14:59 +02:00
Alan SomersandFrederick Mayle 12920cea45 tests: update nix and mio-aio dependencies (#6552)
nix 0.29.0 and mio-aio 0.9.0 use I/O Safety.

Co-authored-by: Frederick Mayle <[email protected]>
2024-05-25 17:30:36 +02:00
Russell Cohen cba86cf1b1 metrics: add MetricAtomicU64 and use in metrics (#6574) 2024-05-23 18:41:01 +02:00
Roy Wellington 16ef7b1fd5 docs: fix stdin documentation (#6581)
The code for `output` indicates that only sets `stdout` and `stderr`, 
yet the docs for `stdin` indicated that it too would be set. This seems 
like it was just a simple copy/paste typo, so correct `stdin` to note
that it just defaults to `inherit`.

Fixes #6577.
2024-05-23 13:52:57 +09:00
Weijia Jiang 1914e1e4b9 time: use sharding for timer implementation (#6534) 2024-05-22 11:54:26 +00:00
二手掉包工程师 e62c3e9269 task: add tokio::task::join_set::Builder::spawn_blocking (#6578)
Signed-off-by: hi-rustin <[email protected]>
2024-05-22 13:35:12 +02:00
M.Amin Rayej 0b651c070f fs: add File::create_new (#6573) 2024-05-22 13:24:48 +02:00
Alice Ryhl a02407171a task: clarify that you can't abort spawn_blocking tasks (#6571) 2024-05-19 16:09:22 +00:00
Michael Scholten daa89017da ci: fix new clippy warnings (#6569) 2024-05-18 10:09:37 +02:00
Alice Ryhl 35c6fd9924 ci: set RUSTUP_WINDOWS_PATH_ADD_BIN=1 (#6568) 2024-05-17 13:03:22 +02:00
Russell Cohen d221c500fa docs: gate taskdump compiler_error behind not(doc) (#6564) 2024-05-16 12:14:07 +02:00
John-John Tedro ced7739f69 tokio: use ptr::addr_of instead of pointer arithmetic in linked_list (#6561) 2024-05-16 10:30:48 +02:00
William Wen 18e048d764 sync: always drop message in destructor for oneshot receiver (#6558) 2024-05-15 13:57:35 +02:00
Weijia Jiang df77063485 time: remove the true_when field in TimerShared (#6563) 2024-05-15 09:32:39 +02:00
Alice Ryhl d085260ee0 metrics: fix flaky injection_queue_depth test (#6559) 2024-05-14 21:01:49 +00:00
Sebastian SchildtandAkhil Thankachan Thomas 227979f091 net: support QNX OS (#6421)
Co-authored-by: Akhil Thankachan Thomas <[email protected]>
2024-05-14 13:11:37 +02:00
Kezhu Wang 6fcd9c0217 macros: make #[tokio::test] append #[test] at the end of the attribute list (#6497) 2024-05-05 16:28:59 +00:00