Skip to content

Optimistic DNS #2145

@lincolnguang

Description

@lincolnguang

Prerequisites

Please answer the following questions for yourself before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.

  • [-] I am running the latest version
  • [-] I checked the documentation and found no answer
  • [-] I checked to make sure that this issue has not already been filed

Problem Description

Optimistic DNS can reduce latency caused by DNS resolution when a client reconnects after a record has expired, which idea from apple in page 13.

Proposed Solution

When the local DNS cache expires, Adguard Home can continue answer with the IP in the local cache results with 1 TTL, while a new DNS query is made to update the cache. If client can still connect to the server by using the old results, then that's great and reduces the time waiting for DNS query. And if not, after a short TTL, the new DNS result can be sent to client and reconnect again.

Additional Information

Also, there is another Go project named Clash support this feature, you can check this pr.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions