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

change: default to cache DNS record according to the TTL #3530

Merged
merged 1 commit into from
Feb 10, 2021

Conversation

spacewander
Copy link
Member

Since lua-resty-dns-client provides an internal cache, we don't need to
cache it twice.

Signed-off-by: spacewander spacewanderlzx@gmail.com

What this PR does / why we need it:

Pre-submission checklist:

  • Did you explain what problem does this PR solve? Or what new features have been added?
  • Have you added corresponding test cases?
  • Have you modified the corresponding document?
  • Is this PR backward compatible? If it is not backward compatible, please discuss on the mailing list first

@spacewander spacewander marked this pull request as ready for review February 5, 2021 10:15
Since lua-resty-dns-client provides an internal cache, we don't need to
cache it twice.

Signed-off-by: spacewander <spacewanderlzx@gmail.com>
Copy link
Member

@membphis membphis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@@ -279,6 +279,12 @@ Please modify "admin_key" in conf/config.yaml .
end
end

if yaml_conf.apisix.dns_resolver_valid then
if tonumber(yaml_conf.apisix.dns_resolver_valid) == nil then
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use JSON Schema to check configuration values?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems that the whole config.yaml doesn't have the json schema.

Copy link
Member

@membphis membphis Feb 6, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it is time to do it in this way now

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's more proper to do it in another PR.

@spacewander spacewander merged commit 653e153 into apache:master Feb 10, 2021
@spacewander spacewander deleted the dns_cache branch February 10, 2021 03:41
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.

4 participants