mirror of
https://github.com/hickory-dns/hickory-dns.git
synced 2026-04-25 19:25:56 +03:00
[GH-ISSUE #3304] Support smol runtime in the resolver #1166
Labels
No labels
blocked
breaking-change
bug
bug:critical
bug:tests
cleanup
compliance
compliance
compliance
crate:all
crate:client
crate:native-tls
crate:proto
crate:recursor
crate:resolver
crate:resolver
crate:rustls
crate:server
crate:util
dependencies
docs
duplicate
easy
easy
enhance
enhance
enhance
feature:dns-over-https
feature:dns-over-quic
feature:dns-over-tls
feature:dnsssec
feature:global_lb
feature:mdns
feature:tsig
features:edns
has workaround
ops
perf
platform:WASM
platform:android
platform:fuchsia
platform:linux
platform:macos
platform:windows
pull-request
question
test
tools
tools
trust
unclear
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hickory-dns#1166
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @CathalMullan on GitHub (Oct 10, 2025).
Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/3304
Is your feature request related to a problem? Please describe.
I'd like the ability to use the resolver crate with
smolinstead oftokio.Describe the solution you'd like
The easiest solution would be to copy the approach previously used by the
async-stdintegration, but forsmol.Describe alternatives you've considered
Alternatively, this might be a good time to make the
protoandresolvercrates truly runtime agnostic. Though that would be much more work.From a quick proof of concept, that would require extending the
RuntimeProvidertrait to handle TCP and TLS connections, and theSpawntrait to replace some freestandingtokio::spawnusages inproto. Then the majority of remaining changes would involve weaving theP: RuntimeProviderthroughout the rest of the codebase.Additional context
The resolver previously supported
async-std, but that was ripped out in #2867 due to its discontinuation.@djc commented on GitHub (Oct 10, 2025):
I'm leaning towards having any smol-based
RuntimeProviderlive outside of this repo, in a separate crate probably not maintained by us.Not sure what you mean by "truly agnostic" but I'm open to reviewing incremental changes that make our library crates more generic by replacing Tokio-specific code with
RuntimeProvider-based API.@CathalMullan commented on GitHub (Oct 10, 2025):
By truly agnostic, I mean agnostic across all protocols/features.
Looking at the
tokio::spawnusages in the h2/h3 stream code, I don't think the oldasync-stdfeature was actually free oftokioruntime code.github.com/hickory-dns/hickory-dns@50f4a1e245/crates/proto/src/h2/h2_client_stream.rs (L533-L537)github.com/hickory-dns/hickory-dns@50f4a1e245/crates/proto/src/h3/h3_client_stream.rs (L433-L445)@djc commented on GitHub (Oct 10, 2025):
Fair -- though I think we just disabled these protocols when the tokio feature was disabled?