#tokioconsole — Public Fediverse posts
Live and recent posts from across the Fediverse tagged #tokioconsole, aggregated by home.social.
-
Async на Rust завис: как понять, где именно, когда паники нет и стек молчит
Сервис жив, CPU в норме, паники нет — а часть запросов зависает на минуты. В async‑Rust привычный стек часто мало помогает: задача могла застрять на блокирующем вызове, мьютексе или просто перестать получать пробуждения. Разбираем, как отличать эти сценарии в Tokio и куда смотреть, когда отладчик молчит.
https://habr.com/ru/companies/otus/articles/1065590/
#Rust #Tokio #async #асинхронное_программирование #зависания #дедлоки #отладка #tokioconsole #мьютексы #кооперативная_многозадачность
-
Did you know that the meaning of all the columns in Tokio Console is documented?
Someone asked about this today, and being able to point to the docs was great!
-
Did you know that the meaning of all the columns in Tokio Console is documented?
Someone asked about this today, and being able to point to the docs was great!
-
I wrote up a post on the size of Futures in #rustlang, why they can be big, why we care and how you can check the size.
This leads into the new instrumentation in Tokio 1.41.0 and new lints in Tokio Console 0.1.13.
And of course there's a link to the Clippy lint that can do much of this statically!
-
I wrote up a post on the size of Futures in #rustlang, why they can be big, why we care and how you can check the size.
This leads into the new instrumentation in Tokio 1.41.0 and new lints in Tokio Console 0.1.13.
And of course there's a link to the Clippy lint that can do much of this statically!
-
There's some new instrumentation in tokio 1.41.0 (released 2 days ago), which includes the size of the future driving every task.
In Tokio Console 0.1.13 (released half and hour ago), not only will you see this value, but there are 2 new lints which will warn you if your futures are perhaps a little too large.
-
There's some new instrumentation in tokio 1.41.0 (released 2 days ago), which includes the size of the future driving every task.
In Tokio Console 0.1.13 (released half and hour ago), not only will you see this value, but there are 2 new lints which will warn you if your futures are perhaps a little too large.
-
Normally I’m not a fan of “system tray” apps. But if someone could create one that tells you when you have #rust target directories that are getting silly large, I’d install that.
Just deleted almost 80GiB of target directory from just my clone of the #tokioConsole project. 🤦♀️
-
Normally I’m not a fan of “system tray” apps. But if someone could create one that tells you when you have #rust target directories that are getting silly large, I’d install that.
Just deleted almost 80GiB of target directory from just my clone of the #tokioConsole project. 🤦♀️
-
Just got a new release of Tokio Console (and supporting crates) out, only a month and a half after the last release!
How did we manage this? Release-plz makes releasing super easy, even when I have to patch the version of tokio-console to avoid a (pre-1.0) major version bump (because tonic upgrades mean we need a major version bump for console-api and console-subscriber).
Check it out: https://release-plz.ieni.dev/
Thank you @MarcoIeni !
-
Just got a new release of Tokio Console (and supporting crates) out, only a month and a half after the last release!
How did we manage this? Release-plz makes releasing super easy, even when I have to patch the version of tokio-console to avoid a (pre-1.0) major version bump (because tonic upgrades mean we need a major version bump for console-api and console-subscriber).
Check it out: https://release-plz.ieni.dev/
Thank you @MarcoIeni !
-
add flags and configurations for warnings
https://github.com/tokio-rs/console/pull/493add --allow flag
https://github.com/tokio-rs/console/pull/513These two features allow you to choose which lints you want running in tokio-console.
Don't want a warning for tasks that have never yielded? It's as easy as:
tokio-console --allow never-yielded
They can all be allowed (no warnings) with:
tokio-console --allow all
-
add flags and configurations for warnings
https://github.com/tokio-rs/console/pull/493add --allow flag
https://github.com/tokio-rs/console/pull/513These two features allow you to choose which lints you want running in tokio-console.
Don't want a warning for tasks that have never yielded? It's as easy as:
tokio-console --allow never-yielded
They can all be allowed (no warnings) with:
tokio-console --allow all
-
lints trigger with non-async tasks
https://github.com/tokio-rs/console/pull/517The lints available in Tokio-console are only really applicable to async and local tasks. Not to the other kinds (blocking, block_on).
Yet the lints were getting triggered on those tasks as well, which were all false positives.
This release includes a fix for that!
-
lints trigger with non-async tasks
https://github.com/tokio-rs/console/pull/517The lints available in Tokio-console are only really applicable to async and local tasks. Not to the other kinds (blocking, block_on).
Yet the lints were getting triggered on those tasks as well, which were all false positives.
This release includes a fix for that!
-
replace target column with kind column in tasks view
https://github.com/tokio-rs/console/pull/478The task kind is more useful (and shorter) than the target, so the kind has been given its own column and target has been relegated to the catch all "Fields" column.
This work also enabled the next fix...
-
replace target column with kind column in tasks view
https://github.com/tokio-rs/console/pull/478The task kind is more useful (and shorter) than the target, so the kind has been given its own column and target has been relegated to the catch all "Fields" column.
This work also enabled the next fix...
-
Don't save poll_ops if no-one is receiving them
https://github.com/tokio-rs/console/pull/501Poll ops were previously not being removed from the console-subscriber local state after the retention period. This is a not-very-nice memory leak.
Since tokio-console doesn't show completed poll ops anyway, they won't be stored in the console-subscriber local state if no client is attached. This will reduce the subscriber memory footprint in that case (no client connected).
-
Don't save poll_ops if no-one is receiving them
https://github.com/tokio-rs/console/pull/501Poll ops were previously not being removed from the console-subscriber local state after the retention period. This is a not-very-nice memory leak.
Since tokio-console doesn't show completed poll ops anyway, they won't be stored in the console-subscriber local state if no client is attached. This will reduce the subscriber memory footprint in that case (no client connected).
-
There is also a minimal gRPC-web client in the console-subscriber examples directory:
https://github.com/tokio-rs/console/pull/526 -
There is also a minimal gRPC-web client in the console-subscriber examples directory:
https://github.com/tokio-rs/console/pull/526 -
Support for gRPC web!
https://github.com/tokio-rs/console/pull/498You can now run Tokio Console with a gRPC-web interface. This would allow you to use a client connecting from a web browser.
Of course, tokio-console is a command line tool, it doesn't run in a web browser, so why would you want this?
Because Tokio Console contributor Rustin has built a web version of the console as well!
Check it out:
https://github.com/hi-rustin/tokio-console-web -
Support for gRPC web!
https://github.com/tokio-rs/console/pull/498You can now run Tokio Console with a gRPC-web interface. This would allow you to use a client connecting from a web browser.
Of course, tokio-console is a command line tool, it doesn't run in a web browser, so why would you want this?
Because Tokio Console contributor Rustin has built a web version of the console as well!
Check it out:
https://github.com/hi-rustin/tokio-console-web -
Reduce retention period to fit in max message size
https://github.com/tokio-rs/console/pull/503This will ensure that even if you have a busy app with no console attached, tokio console will be able to attach and get *some* messages. The retention size is reduced until it fits in the max message size.
-
Reduce retention period to fit in max message size
https://github.com/tokio-rs/console/pull/503This will ensure that even if you have a busy app with no console attached, tokio console will be able to attach and get *some* messages. The retention size is reduced until it fits in the max message size.
-
We just released a new version of Tokio Console. Tokio Console is a debugger for async Rust (running with the Tokio runtime).
This includes new versions of the following crates:
* tokio-console v0.1.11 (https://github.com/tokio-rs/console/releases/tag/tokio-console-v0.1.11)
* console-subscriber v0.3.0 (https://github.com/tokio-rs/console/releases/tag/console-subscriber-v0.3.0)
* console-api v0.7.0Upgrade tokio-console and make sure you use the latest console-subscriber to get the latest features!
A thread of some of the changes.
-
We just released a new version of Tokio Console. Tokio Console is a debugger for async Rust (running with the Tokio runtime).
This includes new versions of the following crates:
* tokio-console v0.1.11 (https://github.com/tokio-rs/console/releases/tag/tokio-console-v0.1.11)
* console-subscriber v0.3.0 (https://github.com/tokio-rs/console/releases/tag/console-subscriber-v0.3.0)
* console-api v0.7.0Upgrade tokio-console and make sure you use the latest console-subscriber to get the latest features!
A thread of some of the changes.
-
The recording of my @rustlab talk “Observing Tokio” is now online!
I talk about about metrics, tokio console, and task dumps!
-
The recording of my @rustlab talk “Observing Tokio” is now online!
I talk about about metrics, tokio console, and task dumps!
-
Now that the @rustconf videos are online I finally got to watch the “Profiling async applications in Rust” talk by Vitaly Bragilevsky (of JetBrains).
It was quite interesting, although I was hoping to learn something more. It was very gratifying to see #TokioConsole on screen though!
-
Now that the @rustconf videos are online I finally got to watch the “Profiling async applications in Rust” talk by Vitaly Bragilevsky (of JetBrains).
It was quite interesting, although I was hoping to learn something more. It was very gratifying to see #TokioConsole on screen though!
-
I recently heard about someone using #tokioConsole from a “custom runtime” (not using the `tokio_unstable` flag). I’m not sure if they meant custom #tokio or a non-tokio custom runtime.
Honestly, either of those happening is pretty cool. I’d love to hear from anyone else doing anything similar too!
-
I recently heard about someone using #tokioConsole from a “custom runtime” (not using the `tokio_unstable` flag). I’m not sure if they meant custom #tokio or a non-tokio custom runtime.
Honestly, either of those happening is pretty cool. I’d love to hear from anyone else doing anything similar too!
-
`console-subscriber` 0.1.10 release: https://github.com/tokio-rs/console/releases/tag/console-subscriber-v0.1.10 (2/2)
Fixes 2
Excessive polling was reported. Specifically the task that spawns a task would get the polling times and counts of the spawned task added to its own. This was incorrect and has now been fixed!
An incorrect clock skew warning in start_poll has been removed. It would trigger when there was no actual clock skew.
-
`console-subscriber` 0.1.10 release: https://github.com/tokio-rs/console/releases/tag/console-subscriber-v0.1.10 (2/2)
Fixes 2
Excessive polling was reported. Specifically the task that spawns a task would get the polling times and counts of the spawned task added to its own. This was incorrect and has now been fixed!
An incorrect clock skew warning in start_poll has been removed. It would trigger when there was no actual clock skew.
-
`console-subscriber` 0.1.10 release: https://github.com/tokio-rs/console/releases/tag/console-subscriber-v0.1.10 (1/2)
Fixes 1
Fix the self wake count. Self wakes were previously not being counted.
This also means that the self wake lint will now get triggered (if a task self wakes more than 50% of the time).
-
`console-subscriber` 0.1.10 release: https://github.com/tokio-rs/console/releases/tag/console-subscriber-v0.1.10 (1/2)
Fixes 1
Fix the self wake count. Self wakes were previously not being counted.
This also means that the self wake lint will now get triggered (if a task self wakes more than 50% of the time).
-
`tokio-console` 0.1.9 release: https://github.com/tokio-rs/console/releases/tag/tokio-console-v0.1.9 (2/2)
Fixes
Removed the confusing minimum histogram count from the poll time and schedule time histograms.
Improve visibility of long file locations in the task and resource detrail views. You now see the end of the file name, including the line and column number. This is probably more useful than the beginning.
-
`tokio-console` 0.1.9 release: https://github.com/tokio-rs/console/releases/tag/tokio-console-v0.1.9 (2/2)
Fixes
Removed the confusing minimum histogram count from the poll time and schedule time histograms.
Improve visibility of long file locations in the task and resource detrail views. You now see the end of the file name, including the line and column number. This is probably more useful than the beginning.
-
`tokio-console` 0.1.9 release: https://github.com/tokio-rs/console/releases/tag/tokio-console-v0.1.9 (1/2)
Help View
There's a new help view modal on all screens when you press `?`. It only shows the control keys now, but that list of keys has been reorganized and may include features you didn't realize were available.
Improved documentation
The docs.rs page for tokio-console now includes a description of all the columns in each view: https://docs.rs/tokio-console/latest/tokio_console/
-
`tokio-console` 0.1.9 release: https://github.com/tokio-rs/console/releases/tag/tokio-console-v0.1.9 (1/2)
Help View
There's a new help view modal on all screens when you press `?`. It only shows the control keys now, but that list of keys has been reorganized and may include features you didn't realize were available.
Improved documentation
The docs.rs page for tokio-console now includes a description of all the columns in each view: https://docs.rs/tokio-console/latest/tokio_console/
-
Yesterday we had a new release of the #TokioConsole crates. That's `tokio-console` 0.1.9 and `console-subscriber` 0.1.10.
Console is a #debugger for #async #rust!
There were fewer new features in this release, but plenty of improvements and fixes.
Let's have a look at what's in there!
-
Yesterday we had a new release of the #TokioConsole crates. That's `tokio-console` 0.1.9 and `console-subscriber` 0.1.10.
Console is a #debugger for #async #rust!
There were fewer new features in this release, but plenty of improvements and fixes.
Let's have a look at what's in there!
-
So yesterday I realised that if you're working on a terminal UI project, you can effectively put screenshots in your commit messages!
https://github.com/tokio-rs/console/commit/26175044cca81cb4a8289841a0c3b458f2d287f1
I can't beleive it took me this long to think of that!
-
So yesterday I realised that if you're working on a terminal UI project, you can effectively put screenshots in your commit messages!
https://github.com/tokio-rs/console/commit/26175044cca81cb4a8289841a0c3b458f2d287f1
I can't beleive it took me this long to think of that!
-
Scheduled time total and histograms in task detail view.
As well as the poll time percentiles and histogram, you get the same for the scheduled time now.
I wrote more about the scheduled time here: https://hegdenu.net/posts/task-scheduled-time-in-console/
-
Scheduled time total and histograms in task detail view.
As well as the poll time percentiles and histogram, you get the same for the scheduled time now.
I wrote more about the scheduled time here: https://hegdenu.net/posts/task-scheduled-time-in-console/
-
Task IDs are now tokio task IDs.
These are the same ones that you can access via the (unstable) API in Tokio:
-
Task IDs are now tokio task IDs.
These are the same ones that you can access via the (unstable) API in Tokio:
-
Unix domain socket support. You can now connect tokio-console to an instrumented application via socket on unix (instead of a TCP port).
Simply specify a path when constructing your ConsoleLayer`:
```rust
let builder = console_subscriber::Builder::default().server_addr(Path::new("/tmp/tokio-console"));
```and then run tokio-console like so:
```sh
tokio-console file://localhost/tmp/tokio-console
``` -
Unix domain socket support. You can now connect tokio-console to an instrumented application via socket on unix (instead of a TCP port).
Simply specify a path when constructing your ConsoleLayer`:
```rust
let builder = console_subscriber::Builder::default().server_addr(Path::new("/tmp/tokio-console"));
```and then run tokio-console like so:
```sh
tokio-console file://localhost/tmp/tokio-console
``` -
Version 0.1.8 of tokio-console, a debugger for async #rust has been released!
Together with console-subscriber 0.1.9, it includes a bunch of new features!
Let's have a look at some of them.
-
Version 0.1.8 of tokio-console, a debugger for async #rust has been released!
Together with console-subscriber 0.1.9, it includes a bunch of new features!
Let's have a look at some of them.