8000 Add a name to the Tokio task by ackintosh · Pull Request #7544 · sigp/lighthouse · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Add a name to the Tokio task #7544

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 3, 2025
Merged

Add a name to the Tokio task #7544

merged 2 commits into from
Jun 3, 2025

Conversation

ackintosh
Copy link
Member
@ackintosh ackintosh commented Jun 2, 2025

Issue Addressed

The console-subscriber feature was added in #7529. However, the names of the running tasks are blank:

image

Proposed Changes

Set the task name using tokio::task::Builder, which is availble when the tokio_unstable is enabled.

image

Additional Info

As you can see in the screenshot, there are many tasks named as libp2p. I think it would be more informative if those tasks were named after their Behaviour name instead of just libp2p (e.g., gossipsub). But that would require changes to rust-libp2p.

@ackintosh ackintosh marked this pull request as ready for review June 2, 2025 14:14
@ackintosh ackintosh added the ready-for-review The code is ready for review label Jun 2, 2025
Copy link
Member
@jimmygchen jimmygchen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me! Definitely make the output a lot useful, nice work!

@jimmygchen jimmygchen added ready-for-merge This PR is ready to merge. and removed ready-for-review The code is ready for review labels Jun 3, 2025
mergify bot added a commit that referenced this pull request Jun 3, 2025
@mergify mergify bot merged commit cd83d8d into sigp:unstable Jun 3, 2025
31 checks passed
@ackintosh ackintosh deleted the task-name branch June 3, 2025 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-for-merge This PR is ready to merge.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0