Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support DNS resolution settings #3690

Closed
guydc opened this issue Jun 27, 2024 · 5 comments
Closed

Support DNS resolution settings #3690

guydc opened this issue Jun 27, 2024 · 5 comments
Labels
area/api API-related issues area/translator Issues related to Gateway's translation service, e.g. translating Gateway APIs into the IR.
Milestone

Comments

@guydc
Copy link
Contributor

guydc commented Jun 27, 2024

Description:
Currently, Envoy Gateway overrides the envoy default values for certain DNS resolution:

cluster.DnsRefreshRate = durationpb.New(30 * time.Second)
cluster.RespectDnsTtl = true

These settings are typically configurable in similar projects (see links below):

  • Istio: dns_refresh_rate
  • Ambassador: respect_dns_ttl
  • Gloo Edge: dns_refresh_rate, respect_dns_ttl

Envoy Gateway can support these settings in BackendTrafficPolicy.

Relevant Links:

@guydc guydc added area/api API-related issues area/translator Issues related to Gateway's translation service, e.g. translating Gateway APIs into the IR. labels Jun 27, 2024
@arkodg
Copy link
Contributor

arkodg commented Jun 27, 2024

should these live in Backend instead ?

@guydc
Copy link
Contributor Author

guydc commented Jun 27, 2024

Minutes from today's community meeting:

  • Where: tweaking these settings makes sense mostly for FQDN endpoints. So, implementing this in the Backend API makes sense.
  • What: dns_refresh_rate, respect_dns_ttl are the knobs that make most sense to expose. Other options like dns type (LOGICAL, STRICT) should be auto-computed by EG.
  • Defaults: current defaults don't have a significant impact, since EG mostly resolves IPs from slices and does not rely on DNS often. When relying on DNS, lookup is less frequent, to reduce load on DNS servers.

@alexwo
Copy link
Contributor

alexwo commented Jul 15, 2024

Hi @guydc / @arkodg ,

Since dns_refresh_rate and respect_dns_ttl are propertie apply to all resolutions within a cluster, and a cluster can have multiple backend destinations, does it still make sense for backends within the same cluster to have different dns settings?

Perhaps using BackendTrafficPolicy would be a better choice, as the settings there can apply directly on the cluster level on a 1:1 basis. So thats more clear, even if multiple backends are configured for this cluster, what apply.

WDYT?

@guydc
Copy link
Contributor Author

guydc commented Jul 15, 2024

Hi @alexwo !

Yes, that's a very good point. I tend to agree that it makes more sense to use BTP here. Only envoy endpoint-level config makes sense in the backend API.

@guydc
Copy link
Contributor Author

guydc commented Jul 17, 2024

This was discussed in the last community meeting. Since we do support "service routing" for services (which relies on envoy to perform DNS resolution against kube-dns), there is value in supporting these settings in BTP, so that they can also apply to Service and not only Backend resources.

@guydc guydc added this to the v1.2.0 milestone Jul 23, 2024
@shawnh2 shawnh2 closed this as completed Aug 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/api API-related issues area/translator Issues related to Gateway's translation service, e.g. translating Gateway APIs into the IR.
Projects
None yet
Development

No branches or pull requests

4 participants