-
Notifications
You must be signed in to change notification settings - Fork 90
change how FGs are enabled in the extension #1301
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
Conversation
a30f70c to
234b7c6
Compare
|
|
||
| {{- define "topologyAwareRouting.enabled" -}} | ||
| {{- if and .Values.gardener.seed .Values.gardener.seed.spec.settings.topologyAwareRouting.enabled }} | ||
| {{- if ((((((.Values.gardener).seed).spec).settings).topologyAwareRouting)) -}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the removal of .enabled intentional?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also is it safe this way, or will it error if any intermediate map is missing?
How about?
{{- if (.Values | dig "gardener" "seed" "spec" "settings" "topologyAwareRouting" "enabled" false) }}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let me test that suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just FYI, yes, the original method defaults to empty value (hence false) if an intermediate method is missing
| {{- range $key, $value := .Values.config.featureGates }} | ||
| {{ $key }}: {{ $value }} | ||
| {{- end }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Although this works it will produce random key order, causing noisy diffs between renders.
Could be resolved by:
{{- range $k := (.Values.config.featureGates | keys | sortAlpha) }}
{{ $k }}: {{ index $.Values.config.featureGates $k }}
{{- end }}
418aea1 to
3bbbabf
Compare
|
This update refactors the Helm chart for the Azure provider extension to improve maintainability and flexibility. The logic for evaluating certain settings has been simplified. More significantly, the handling of feature gates is now dynamic, allowing new gates to be added via configuration without requiring template modifications. The example controller registration has been updated to incorporate these chart enhancements. Walkthrough
Model: gemini-2.5-pro | Prompt Tokens: 13672 | Completion Tokens: 156 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
How to categorize this PR?
/area control-plane
/kind enhancement
/platform azure
What this PR does / why we need it:
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Release note: