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

Consult zone endpoints while removing unhealthy records #293

Open
maksymvavilov opened this issue Nov 7, 2024 · 1 comment
Open

Consult zone endpoints while removing unhealthy records #293

maksymvavilov opened this issue Nov 7, 2024 · 1 comment

Comments

@maksymvavilov
Copy link
Contributor

maksymvavilov commented Nov 7, 2024

Why

Currently, we never remove endpoints from the provider when they fail health checks. This is done to prevent NXDomain response. We expect the dns-operator to run in the multicluster environment. This means other controllers could work towards the same root domain and removing endpoints unhealthy endpoints of one of them from the provider might be safe.

What

Consult the DNSRecord.Status.ZoneEndpoints when removing unhealthy records. We want there always to be a chain of endpoints from the root domain to a leaf

How

Two unknowns:

  • How to prevent multiple controllers from removing the records at the same time (validation before deletion). We could use a TXT record to mark the intention to delete unhealthy and consult that record when making the decision.
  • Do we need to maintain the tree struct for managing the chain of endpoints? The alternative is just a search for a leaf.

Completed after:

  1. During the removal of endpoints we consult zone endpoints
  2. Added test case for multiple controllers deleting at the same time.
@maleck13 maleck13 changed the title Consult zope endpoints while removing unhealthy records Consult zone endpoints while removing unhealthy records Nov 11, 2024
@maksymvavilov maksymvavilov self-assigned this Nov 21, 2024
@maksymvavilov
Copy link
Contributor Author

Also can fix a bug - when determining if reconciling prematurely compare each probe to the dnsrecord status instead of comparing them to each other. Comparing to each other always leads to one false result over 6 possibilities. Comparing to the probe enables us to always have true result

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Todo
Development

No branches or pull requests

1 participant