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

Idea/speculative: Dynamic weighting values based on meta data analysis #349

Open
maleck13 opened this issue Jan 22, 2025 · 0 comments
Open
Labels
enhancement New feature or request

Comments

@maleck13
Copy link
Contributor

What

Currently you have to set static weighting values for your DNSPolicy. Changing these means a human making a change and redeploying the DNSPolicy.

Why might you want to change the weighting and what if we could allow that to happen programatically based on some external meta data? Is this even something desirable?

Imagined Use Case

When some of the pods responding to requests coming into this gateway listener are running "hot" for a long time, I want to reduce the amount of traffic being sent to this gateway. To know this I want to query alerts firing in this cluster and if a particular alert is firing set the weight to a lower value.

If all clusters are under pressure, they will all start reducing their weighting. Is this a bad thing as if they are all reducing their weighting then it will effectively end up evenly weighted again right?

The existing weighting field would serve as a default weight but you would be able to set a "conditionalWeight"

Speculative API

loadbalancing:
  weight: 100
conditional:  
- weight: 50
   when:
     - predicate: 'alerts.overloaded == "firing"'

Of course this presumes that the DNS operator has access to the data which is another piece entirely but has prior art in things like authorino

@maleck13 maleck13 added the enhancement New feature or request label Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: No status
Development

No branches or pull requests

1 participant