Rearrange new DNS classes without changing behavior#9584
Open
swankjesse wants to merge 2 commits into
Open
Conversation
Transport is now DnsQuery.Factory CachingTransport is now DnsCache StateMachineDnsCall.Query is now DnsQuery This is intended to make it possible to have end-users get a DnsCache instance without being exposed to the implementation details of our transports and things.
swankjesse
force-pushed
the
jwilson.0723.rearrange
branch
from
July 24, 2026 00:28
5d51a1e to
a27c476
Compare
swankjesse
force-pushed
the
jwilson.0723.rearrange
branch
from
July 24, 2026 00:37
1e994ef to
d58be51
Compare
yschimke
approved these changes
Jul 24, 2026
| * This is different from `Dns.Call` which returns multiple record types. | ||
| */ | ||
| @OkHttpInternalApi | ||
| interface DnsQuery { |
yschimke
approved these changes
Jul 24, 2026
| @OkHttpInternalApi | ||
| @OptIn(ExperimentalTime::class) // We know Clock and Instant will be stable in Kotlin 2.3. | ||
| class CachingTransport<Q>( | ||
| class DnsCache( |
Collaborator
There was a problem hiding this comment.
If we want android apps using this with system sources, we will need to hook into network changes.
For DNS over Https it seems fine.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Transport is now DnsQuery.Factory
CachingTransport is now DnsCache
StateMachineDnsCall.Query is now DnsQuery
This is intended to make it possible to have end-users get a DnsCache instance without being exposed to the implementation details of our transports and things.