Skip to content

Conversation

@bts
Copy link

@bts bts commented Jan 15, 2026

Hi there -- thanks so much for hyper!

Per hyperium/hyper#3904, the tracing feature previously attached the current span to all futures spawned by TokioExecutor::execute. This caused application-level spans to incorrectly extend beyond their intended endpoints when background tasks (connection dispatchers, pool maintenance) outlived the original request.

It seems like clients requiring span propagation should probably instead instrument futures at their call sites of execute, or implement their own Executor<Fut> as needed per their context (e.g. attaching to some separate root span).

This change removes the incorrect span propagation, but keeps the tracing feature flag for backwards compatibility.

Thanks for your consideration!

The `tracing` feature previously attached the current span to all
futures spawned by `TokioExecutor::execute`. This caused
application-level spans to incorrectly extend beyond their intended
endpoints when background tasks (connection dispatchers, pool
maintenance) outlived the original request.

The `tracing` feature flag is preserved as a no-op for backwards
compatibility. Clients requiring span propagation should wrap futures
manually or implement their own `Executor<Fut>`.

See hyperium/hyper#3904 for more information.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant