feat(console): replace target column with kind column in tasks view #478
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In the
tokio-consoletasks view, there are a fixed set of columns andany remaining fields are included in a "Fields" column at the end. One
of the fields which is always present on a task, but doesn't receive a
dedicated column is the kind field, which currently takes one of the
following values:
task(a "normal" async task)blockingblock_onlocalMeanwhile, there is a dedicated column for the task span's target, which
currently takes one of the following values:
tokio::tasktokio::task::blockingThe target for tasks with kind
block_onandlocalis alsotokio::task.This change replaces the target column with a kind column as it provides
more information in fewer characters. The target value is moved
(somewhat artificially) to the fields which appear in the final column.
The
targetis also left on thestate::Taskstruct as we expect towant to filter by it in the future.
Additionally, the
console-subscriberexamples have been updated sothat there are options to visualize
blocking,block_on, andlocaltasks. The
appexample has been updated to include an optional taskwhich calls
tokio::spawn_blocking. A new examplelocalhas beenadded which creates a
LocalSetand spawns local tasks onto it.