Skip to content

Conversation

Tudyx
Copy link
Contributor

@Tudyx Tudyx commented Oct 1, 2025

This PR uses with_cancellation_token_owened inside the TaskTracker documentation. This avoids using the select! macro. The rationale is one described inside the select! documentation :

The select! macro is a powerful tool for managing multiple asynchronous branches, enabling tasks to run concurrently within the same thread. However, its use can introduce challenges, particularly around cancellation safety, which can lead to subtle and hard-to-debug errors. For many use cases, ecosystem alternatives may be preferable as they mitigate these concerns by offering clearer syntax, more predictable control flow, and reducing the need to manually handle issues like fuse semantics or cancellation safety.

@Tudyx Tudyx force-pushed the use-FutureExt-in-TaskTracker-doc branch from ef38b81 to ff84a29 Compare October 1, 2025 20:04
@ADD-SP ADD-SP added A-tokio-util Area: The tokio-util crate T-docs Topic: documentation M-task Module: tokio/task labels Oct 2, 2025
Copy link
Member

@ADD-SP ADD-SP left a comment

Choose a reason for hiding this comment

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

Thanks!

@ADD-SP ADD-SP changed the title use FutureExt in TaskTracker doc task: improve the docs of TaskTracker Oct 2, 2025
@ADD-SP ADD-SP changed the title task: improve the docs of TaskTracker task: simplify the docs of TaskTracker Oct 2, 2025
@ADD-SP ADD-SP changed the title task: simplify the docs of TaskTracker task: simplify the example of TaskTracker Oct 2, 2025
@ADD-SP ADD-SP merged commit d0953e8 into tokio-rs:master Oct 2, 2025
100 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-tokio-util Area: The tokio-util crate M-task Module: tokio/task T-docs Topic: documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants